Best of JVMAugust 2024

  1. 1
    Article
    Avatar of infoworldInfoWorld·2y

    Better than reflection: Using method handles and variable handles in Java

    MethodHandles and VarHandles present safer and more performant alternatives to Java's reflection API. They allow programmatic access to methods and fields with a cleaner and more structured API. While they don't cover all the capabilities of reflection, they are preferred for accessing class metadata and manipulating methods and fields. Migrating away from reflection is necessary as it becomes deprecated, and the JVM is increasingly adopting these new methods.

  2. 2
    Article
    Avatar of justjavaJust Java·2y

    Serialization in Java: A Quick Insight on serialVersionUID 🚀

    The post delves into the significance of serialVersionUID in Java serialization. It explains how this unique identifier ensures compatibility during deserialization, preventing InvalidClassException. Explicitly declaring serialVersionUID helps maintain backward compatibility, avoid issues in distributed environments, and control serialization changes. Guidance is provided on when to update the serialVersionUID based on the nature of class changes.

  3. 3
    Article
    Avatar of jetbrainsJetBrains·2y

    Hacking a JVM Application With IntelliJ IDEA’s Debugger

    The post explores using IntelliJ IDEA's debugger to modify the behavior of a JVM application, specifically adding 'god mode' to a Space Invaders game plugin. It covers setting up multiple IDE instances, configuring JVM options, and using the debugger's memory view and non-suspending breakpoints to change object properties and automate state modifications.