What is new features in Java 13?

What is new features in Java 13?

Due in late 2019, Java 13 is tentatively slated to gain raw string literals and a tool for packaging self-contained Java apps

While the OpenJDK reference webpage for Java Development Kit (JDK) 13 does not yet list any new features, a few proposals are said to be targeted for the release. These proposals cover packaging, unused heap memory, and application class-data sharing.

The new features coming to Java 13

JDK 13 is due September 17, 2019, following rampdown and release candidate stages occurring in coming months. JDK Enhancement Proposals eyed for the release cover:

  • Development of a tool for packaging self-contained Java applications, called jpackage. The tool would be based on the JavaFX javapackagertool that supports native packaging formats to give the user a natural installation experience. It allows launch-time parameters to be specified at packaging time. The tool can be invoked directly from the command line or programmatically via the ToolProvider. Many applications need to be installed on a native platform in a “first-class” way rather than being placed on the class path or module path. A packaging tool also can fill gaps left by technologies such as Java Web Start, which was removed from Oracle’s JDK 11. The javapackagertool was deleted from JDK 11 as part of the removal of JavaFX.
  • Enhancing the ZGC (Z Garbage Collector) to return unused memory to the operating system, a proposal cited as integrated into JDK 13. ZGC, which is billed as a scalable, low-latency collector, currently does not return unused memory back to the OS even if the memory has not been used in a long time. This behavior is not optimal for some applications and environments, especially those where memory footprint is a concern, such as containers or environments where an application might be idle for a long time and is sharing or competing for resources with other applications.
  • Extending application-class data sharing (AppCDS) to enable dynamic archiving of classes at the end of application execution. Archived classes would include all loaded application and library classes not present in the default, base-layer CDS archive. This proposal, which is in the targeted stage, is intended to improve the usability of AppCDS and eliminate the need for users to do trial runs to create a class list for each application.

Also expected in JDK 13

Two capabilities anticipated for JDK 13 have been cited previously by Mark Reinhold, chief architect of the Java platform group at Oracle:

  • Raw string literals, which can span multiple lines of source code and do not interpret escape sequences. This capability had been cut from JDK 12, which arrived in March 2019. The plan is to offer raw string literals only as an opt-in beta in JDK 13. Its goal is to make development easier n Java by, for example, letting developersexpress sequences of characters in a readable form free of Java indicators, or supply strings targeted for grammars other than Java. Following the expected test run in JDK 13, raw string literals could be made production-qiality in the subsequent JDK 14 release.
  • A production version of switch expressions, for which JDK will offer a beta implementation. The switch statement will be extended for use as either a statement or an expression, so both could use either a “traditional” or “simplified” scoping and control flow behavior.

You can download the JDK 13 builds from the jdk.java.net website. The first JDK 13 beta builds are available for Linux, MacOS, and Windows.

Thanks for reading

If you liked this post, share it with all of your programming buddies!

Follow us on Facebook | Twitter

Learn More

Java Programming Masterclass for Software Developers

Selenium WebDriver with Java -Basics to Advanced+Frameworks

Java In-Depth: Become a Complete Java Engineer!

JSP, Servlets and JDBC for Beginners: Build a Database App

JSP, Servlet, JSLT + Hibernate: A complete guide

Java Spring - Limiting Query Result with Spring Data JPA

String Initialization in Java

Spring Boot + JPA + Hibernate + Oracle

A Study List for Java Developers

Java Hibernate Tutorial for Beginners

This story was originally published by InfoWorld.

Angular 9 Tutorial: Learn to Build a CRUD Angular App Quickly

What's new in Bootstrap 5 and when Bootstrap 5 release date?

Brave, Chrome, Firefox, Opera or Edge: Which is Better and Faster?

How to Build Progressive Web Apps (PWA) using Angular 9

What is new features in Javascript ES2020 ECMAScript 2020

Java Fundamentals: Learn Java for absolute beginners |Simpliv

Java Fundamentals: Learn Java for absolute beginners

Java Essentials : Learn Core Java From Basic to Advance

Learn Java Programming Using Practical Assignments. Start Building Back-end Web Applications Robust Test Automation Frameworks By End Of The Course. Learn More!

Fundamentos de Java: Aprende Java desde cero, sin misterios | Simpliv

Fundamentos de Java: Aprende Java desde cero, sin misterios