New features of jdk14

In the release on September 17, Oracle mentioned that the function of switch expression is expected to be finalized in jdk14. In my previous articles, I mentioned that in jdk12 and jdk13, the switch expression is introduced as an experimental syntax. After three versions of iteration, it is natural for the switch expression to be officially launched.

It will also include an update to JDK enhancement proposal (JEP): Java's mapped byte buffers will support non volatile memory (NVM). This will allow filechannel to create mappedbyte buffer instances pointing to NVM.

NVM enables programmers to build and update program state across programs without incurring significant replication or transfer costs typically required for input and output operations. This is particularly important for trading procedures. Therefore, the main goal of this JEP is to ensure that clients can consistently and effectively access and update NVM from Java programs.

Another goal is to use the JDK internal API unsafe to implement this function, which can be used by other classes that want to submit to NVM except mappedbytebuffer. It also provides the ability to track buffers on NVM maps using existing APIs for monitoring and management.

According to Oracle's plan, jdk14 will be released in March 2020 after a six-month release cycle. Jdk14 will be a non lts (non long-term support version) and will only support for 6 months.

If you are interested, you can https://jdk.java.net/14/ Download its preview version from.

have fun !

For more tutorials, please refer to flybean's blog

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>