AT
Apache TinkerPop•13mo ago
Moe

using tinkerpop 3.6.x on a jdk 21 project

I'm using tinkerpop 3.6.5 to read/write over an AWS neptune graph database. Is there any issues using this library on a jdk 21 project ? While the doc says "You can now run TinkerPop with Java 17." : https://issues.apache.org/jira/browse/TINKERPOP-2703 I have the impression it's only regarding Gremlin console that I do not use. With a simple project using DriverRemoteConnection I was able to open a connection and read something from the graph. Everything compiles So I was wondering if there is something documented about this
Solution:
I've not personally tried JDK21 so I can't say for sure how TinkerPop and its dependencies will behave. Note that as of right now we do not use any features of Java beyond JDK8, continually test builds on JDK8, 11 and 17 and that we release on JDK8 bytecode. So presumably, any JDK that can run JDK8 should be able to use TinkerPop without trouble. In practice of course it's hard to say that there aren't subtle differences among JDK versions that you could encounter. As an example, I can think of...
Jump to solution
7 Replies
Solution
spmallette
spmallette•13mo ago
I've not personally tried JDK21 so I can't say for sure how TinkerPop and its dependencies will behave. Note that as of right now we do not use any features of Java beyond JDK8, continually test builds on JDK8, 11 and 17 and that we release on JDK8 bytecode. So presumably, any JDK that can run JDK8 should be able to use TinkerPop without trouble. In practice of course it's hard to say that there aren't subtle differences among JDK versions that you could encounter. As an example, I can think of a few exception messages that have changed among versions.
Moe
MoeOP•13mo ago
Thank you for your input. But ultimately there's nothing that prevents using jdk21 ?
spmallette
spmallette•13mo ago
not that i am aware of. it would be great if you could just give it a try and share your findings back here 🙂
Moe
MoeOP•13mo ago
For now I just created a project (as I mentioned) where I've added the dependency version 3.6.5 and made quick traversal to fetch a vertex and it seemed to work fine. But since in the documentationon there's that sentence "You can now run TinkerPop with Java 17" we thought that it would be prudent to stay with JDK 17 instead But jdk 21 has various improvements that we could benefit from later on (virtual threads) so I was curious and having a look why can't we use the latest version instead.
spmallette
spmallette•13mo ago
i think that statement was built on the excitement that we actually got the build to work on jdk17 🙂 - it was not a simple task and took some serious debugging and profiling to work past a major performance problem that came with the upgrade (not directly caused by the JDK upgrade but related). we were blocked for months (years??) on that issue no one could figure it out, until an unlikely and quiet hero emerged from the internet with a solution. this hero was @Kennh
Moe
MoeOP•13mo ago
Do you think there will be a build on jdk 21 any time soon ?
spmallette
spmallette•13mo ago
it's not been discussed in the community as of yet so i'm not sure if "soon" is on the table. i think i'd prefer to talk about dropping the build for JDK8 so that we could use newer java features in our code and give us one less JDK to maintain. that said, an upgrade to 21 isnt' always dependent on our choices either...often we are blocked by dependencies. like does Apache Spark/Hadoop/Groovy work on JDK21 - if not, we're a bit stuck anyway. In any case, if 21 is important to you, please feel free to jump in and help push that agenda forward. you would want to subscribe to the TinkerPopo dev list and start a "[DISCUSS]" thread there on the topic to start to engage the community on the idea and see where it goes from there.
Want results from more Discord servers?
Add your server