Inside Java is a podcast for Java Developers brought to you directly from the people that make Java at Oracle. We'll discuss the language, the JVM, OpenJDK, platform security, innovation projects like Loom and Panama, and everything in between!
Curated by: Java (52 videos)
In this episode, David remotely sat down with Brent Christian to discuss finalization and the effort to gradually deprecate this now outdated, brittle, and complex mechanism from the platform. After covering some of the (many!) finalization weaknesses, Brent discusses the alternatives to properly deal with resources, i.e. try with resources and the Cleaner API. He then continues with JEP 421 which will be part of JDK 18 and some potential subsequent steps. Make sure to check the episode page ➱ https://inside.java/podcast/21 ⎯⎯⎯⎯⎯⎯ Resources ⎯⎯⎯⎯⎯⎯ ◦ JEP 421: Deprecate Finalization for Removal ➱ https://openjdk.java.net/jeps/421 ◦ JDK 18 ➱ https://jdk.java.net/18/ ◦ `java.lang.Object.finalize()` warning ➱ https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#finalize() ◦ Try With Resources ➱ https://dev.java/learn/catching-and-handling-exceptions/#anchor_6 ◦ Cleaner API ➱ https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/ref/Cleaner.html ◦ The `jdeprscan` tool ➱ https://docs.oracle.com/en/java/javase/17/docs/specs/man/jdeprscan.html ◦ Why is the `finalize` method deprecated? ➱ https://inside.java/2021/11/03/why-is-finalize-deprecated/ ⎯⎯⎯⎯⎯⎯ Additional Resources ⎯⎯⎯⎯⎯⎯ ◦ Dev.java: The Destination for Java Developers ➱ https://dev.java ◦ Oracle Java ➱ https://www.oracle.com/java/ ◦ OpenJDK ➱ https://openjdk.java.net/ Categories: #Java #Java18 #OpenJDK