knowm / XChange

XChange is a Java library providing a streamlined API for interacting with 60+ Bitcoin and Altcoin exchanges providing a consistent interface for trading and accessing market data.
http://knowm.org/open-source/xchange/
MIT License
3.85k stars 1.94k forks source link

Enable Compilation on JDK21 #4859

Closed rvullriede closed 5 months ago

rvullriede commented 5 months ago

The currently used lombok version is not compatible with JDK 21. In addition, Its advised to switch from source/target to release (see https://openjdk.org/jeps/247 for details), introduced in Java 9. The maven compiler plugin with translate this automatically to the old source/target/bootclasspath options for Java 8 compilers.

rizer1980 commented 5 months ago

Hello. Maybe it’s worth separating these (OHLC for Kraken, JDK 21) for two separate PR?

rvullriede commented 5 months ago

@rizer1980, sorry that was unintentional. I'll cleaned this up. In addition, I noticed that meanwhile the problematic lombok dependency was updated already. What remains are the more robust compilation settings.

bigscoop commented 5 months ago

How about changing the code level to 11? Since we're anyway building witth SDK 11. What do you think, @timmolter ?

timmolter commented 5 months ago

@bigscoop ok, let's try it after the next release (coming this week). That way Java 11 will be present in the SNAPSHOT versions for a while before releasing it. We've tried several times in the past, but people reported issues with Android. Maybe it will work out this time around.