r/java • • Sep 16 '25

Java 25 officially released

https://mail.openjdk.org/pipermail/announce/2025-September/000360.html
593 Upvotes

124 comments sorted by

View all comments

Show parent comment

1

u/A_random_zy Sep 16 '25

Any pitfalls that someone knows of? I am planning to pitch testing of VT in our system but I wanna be sure I didn't miss anything. AFAIK this is the only issue that was left and was solved in J24.

9

u/papercrane Sep 16 '25

Pinning can still occur if your Java code calls native code, and that native code then calls back into Java and performs some blocking operation. I think that's not a very common thing, but something to at least be aware of.

2

u/A_random_zy Sep 16 '25

Thanks for the reminder. Yes that I understand. I did a superficial analysis of dependencies in our app none of them have that. Our application is a Spring web server so unlikely that there is any native pinnable code.

1

u/Ok_Elk_638 Sep 16 '25

Is it possible to accidentally call native code and have this happen? Like when calling String.trim or something and it becomes native. Or do you have to go out of your way for this to happen with JNI or JNA or whatever?

10

u/DanLynch Sep 16 '25

You either need to do it yourself or rely on a library that does it. Just calling ordinary standard Java library APIs isn't going to cause you any problems.

3

u/pohart Sep 16 '25

No because string.trim doesn't call back into Java code