-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Thrift client throws: NoSuchMethodError: java.nio.ByteBuffer.clear()Ljava/nio/ByteBuffer #839
Comments
I've update the issue with a full reproduction example to make debugging easier. Please let me know if you need more details. Thanks! |
I did some more testing: I built finagle/scrooge/util from the 20.4.0 tag both with Java 8 and Java 11. The Java 8 build also works with the above test case under Java 8. The Java 11 build fails as described. I'm not familiar with your build/release setup, but my assumption is that you're building the artifacts with Java 11, while still targeting Java 8 bytecode. The official recommendation is also to build everything with Java 8 for now, see https://docs.scala-lang.org/overviews/jdk-compatibility/overview.html Can you change the release process to build with Java 8 (for now at least)? Or do you have an idea on how to work around this without upgrading everything to Java 11 on our side? |
@bryce-anderson @ryanoneill @illicitonion @yufangong Please let me know if you need more details or if I can help out in any way. |
@dziemba nice work on getting to the bottom of this. +1 for java 8 build. I can't upgrade to finagle 20.4.0 without it because scala recommends compiling with java 8 In addition this ticket states that Java 8 is the version used internally at Twitter. Is there a mismatch between what version of Java is used to build finagle and the expected Java version? |
@dziemba thanks for posting this and the relevant details. This release went through some hiccups in our process and environment, specifically around jdk versions, and this issue is likely a fallout from that. We're working to address this and figure out a path forward, but it sounds like 20.4.0 is a bad artifact. We will update as we know more and can give an ETA on the next release. |
Awesome, thanks @roanta |
The issue seems to be fixed in v20.4.1. Thanks a lot @roanta! 🙂 |
That's great! Credit to @yufangong for fixing the underlying issues and doing a followup release! |
When using the thrift client, it throws a
NoSuchMethodError
when running on Java 8. Running on Java 11 works fine. This has been happening since finagle 20.4.0 (20.3.0 works fine).Expected behavior
Thrift client works as expected.
Actual behavior
It throws:
Steps to reproduce the behavior
Example code:
Full example (
sbt run
able): https://github.com/dziemba/finagle-issue-839It works fine on Java 11, but fails with the above exception on Java 8 (1.8.0_242)
You don't need to start a server of any kind, it throws before it tries to make a connection.
The text was updated successfully, but these errors were encountered: