Am 2019-03-01 um 16:48 schrieb Thiebaud, Christophe:
[FYI]



Got



java.lang.NoSuchMethodError: java.nio.ByteBuffer.rewind()Ljava/nio/ByteBuffer;



When running my 
tools<https://github.com/aequologica/quintessence/blob/develop/quintessence-core/src/main/java/net/aequologica/neo/quintessence/jaxrs/Resource.java>
 with java8 and the maven-resolver 
1.3.2<https://search.maven.org/artifact/org.apache.maven.resolver/maven-resolver/1.3.2/pom>



Google says :



“compiling with a java 9 compiler (using -source 1.8 -target

1.8 like our build does), then the resulting jar file cannot actually

be used with a java 8 JVM.



The reason is, in java 9 ByteBuffer.class got some new covariant overrides:

e.g. ByteBuffer.java has position(int) that returns ByteBuffer, but

this does not exist on java 8 (the position method is only in

Buffer.java returning Buffer).”



Is compatibility with java 8 dropped ?

Snaps, I have seens this already somewhere. The outcome was to typecast explicitly to get correct bytecode.

@Karl, did you compile with JDK 8 only?

Michael


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to