Jawa

Java 10 New Features

Java 10 New Features

What's New in Java 10 and What are the Future Plans?

Recently Java has changed the pace of releases. Previously, it would take years to come up with a new Java version. But Java 10 was released into the world only six months after Java 9. It seems Oracle is going to try to get new Java versions to developers as soon as possible. Faster release of Java versions means that developers will have access to new features sooner. On the other hand, fast developer adoption will lead to more Java popularity. So, it's a win-win for both parties.

What's New?

Here are some of the important Java 10 features:

Local Variable-Type Inference: Java requires explicitly typed variables to ensure “type safety”. It is used as a design principle to minimize runtime errors. However, explicitly typing variables for loop iterators and intermediate values make Java programming time-consuming and error-prone. With local variable-type inference, Java compiler will be able to infer the type of a variable from context. It should speed up programming in Java.

Parallel Full GC for G1 Garbage Collector: Sometimes garbage collection gets priority over running program and the program execution is frozen to give garbage collection exclusive access to the JVM. This is known as “Full Garbage Collection”. In Java 10, this process has been optimized to run parallel threads on multiple processors. It makes the process more efficient.

Application Class Data Sharing: It will optimize startup time and footprint. If a jar doesn't change, then class-data also doesn't change. Once the class-data is created, it can be put in an archive and reused across multiple JVMs.

Experimental JIT Compiler: Just-in-time (JIT) compilers help developers write efficient applications. But Java's JIT compiler was written in C++. The new JIT is Java-based. It will make it easier for developers to maintain the code.

Docker Awareness: Java 10 JVM will know if it is running in a Docker container. Instead of talking to the operating system directly, the JVM will get the information from the Docker container.

Consolidate the JDK Forest into a Single Repository: Various JDK forests are combined into a single repository. It improves housekeeping and streamlines development.

Heap Allocation on Alternative Memory Devices: HotSpot VM will be able to allocate Java object heap on an alternative user-defined memory device.

Root Certificates: JDK 10 is has been developed with the cooperation of OpenJDK. It will provide a default set of root Certification Authorities.

Future Plans

Here are some future considerations for Java:

Conclusion

The new fast-paced release cycles mean that features might get pushed to the next release more often than before. But overall, JDK 10 features should be great for everyone.

References:

AppyMouse On-screen Trackpad and Mouse Pointer for Windows Tablets
Tablet users often miss the mouse pointer, especially when they are habitual to using the laptops. The touchscreen Smartphones and tablets come with m...
Middle mouse button not working in Windows 10
The middle mouse button helps you scroll through long webpages and screens with a lot of data. If that stops, well you will end up using the keyboard ...
How to change Left & Right mouse buttons on Windows 10 PC
It's quite a norm that all computer mouse devices are ergonomically designed for right-handed users. But there are mouse devices available which are s...