Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
JDK9
KUBOTA Yuji (@sugarlife)
Java Japan User Group LT with b33r
10/Aug/2015
Attention
•Depends on OpenJDK project.
•This slide provides only the
summary for LT. Something
may have been changed until...
Who am I
•KUBOTA Yuji (@sugarlife)
•icedtea committer
(HeapStats)
•OpenJDK Contributor
•JavaOne Speaker
•Hard-hearing pers...
JDK9 Schedule
•2015/12/10: Feature Complete
• : Many tests
•2016/07/21: Final Release
Candidate
•2016/09/22: General Avail...
What features will come?
102: Process API Updates
110: HTTP 2 Client
143: Improve Contended Locking
158: Unified JVM Loggi...
What features will come?
102: Process API Updates
110: HTTP 2 Client
143: Improve Contended Locking
158: Unified JVM Loggi...
Give it a once-over!
•This color’s feature is important
for ME who develop the product
depends on JVM.
•This color’s featu...
102: Process API Updates
•Do you want information
about process? ok, here is.
110: HTTP 2 Client
•Do you want API for
HTTP/2 ? ok, here is.
143: Improve Contended Locking
•Good speed for contended
java object monitors.
•JVM will get a better
performance without ...
158: Unified JVM Logging
•Shall we unify the log format of
JVM: e.g. compiler, gc,
classload, metaspace, etc...
•If you de...
165: Compiler Control
•I WANNA CONTROL COMPILER
MORE DETAIL!
•You (probably JVM tester) can
•add some order when specified...
193: Variable Handles
•sun.misc.Unsafe may be removed.
•So we prepare the alternatives.
This JEP is the first step for it.
(おまけ) sun.misc.Unsafe 動向
• 6/15-16 に行われた JCP Executive Committee Meeting で隠蔽・削除
に向けた影響や代替方法などの話し合いが行われた
• 元々 sun.* 等は Jigs...
197: Segmented Code Cache
•Code cache diet.
•JVM will get a better
performance without change
of your codes.
199: Smart Java Compilation, Phase
Two
•sjavac.
201: Modular Source Code
•JDK source code into
modules.
•A part of Project Jigsaw.
•If you read OpenJDK source
code, you n...
211: Elide Deprecation Warnings
on Import Statements
•Lint warnings is cry-wolf?
•javac always show warning
when you impor...
212: Resolve Lint and Doclint
Warnings
•To clean lint and doclint
errors of some JDK
components.
213: Milling Project Coin
•Add language changes.
•@SafeVargs on private methods
• non-overridable executable.
•improve try...
214: Remove GC Combinations
Deprecated in JDK 8
•Good bye following GC Combi.
•DefNew + CMS
•ParNew + SerialOld
•DefNew + ...
215: Tiered Attribution for javac
•New type checking in javac.
•If you have interest in “type” in
compiler, you should rea...
216: Process Import Statements
Correctly
•Fix javac.
217: Annotations Pipeline 2.0
•javac again.
219: Datagram Transport Layer
Security (DTLS)
•API for DTLS 1.0 (RFC 4347)
and DTLS 1.2 (RFC 6347)
220: Modular Run-Time Images
•Restructure the JDK and JRE
to accommodate modules.
•A main part of Project Jigsaw
•Many ris...
221: Simplified Doclet API
•Replace Docklet API
(com.sun.javadoc) .
222: jshell: The Java Shell (Read-
Eval-Print Loop)
•No need more Test.java!
•An interactive tool for Java
programming lan...
223: New Version-String Scheme
•Change version-string format.
•Security update 2 times +
Minor update 1 times
•Current
• l...
224: HTML5 Javadoc
http://www.w3.org/html/logo/
226: UTF-8 Property Files
•You will be enable to use
UTF-8 property files.
227: Unicode 7.0
•You will..( see title.
228: Add More Diagnostic
Commands
•Add below commands
•print_class_summary (loaded classes)
•print_codegenlist (method que...
229: Create PKCS12 Keystores
by Default
•Improve security.
230: Microbenchmark Suite
•JMH++
•Add a basic suite of
microbenchmark to JDK codes.
231: Remove Launch-Time JRE
Version Selection
•Remove forgotten options.
•“-version:” option
•Not “-version” option
•“JRE-...
232: Improve Secure Application
Performance
•Good speed with a security
manager installed.
233: Generate Run-Time
Compiler Tests Automatically
•Generate jtreg-compatible
automatically for openjdk
developers.
•If y...
235: Test Class-File Attributes
Generated by javac
•yes, javac.
236: Parser API for Nashorn
•To get IDE support for
Nashorn.
237: Linux/AArch64 Port
•ARM®
240: Remove the JVM TI hprof
Agent
•Good bye hprof
•See also (alternatives)
•OProfile
•perf
•YourKit
•SystemTap (for debug)
241: Remove the jhat Tool
•Good bye jhat
•See also (alternatives)
•Eclipse MAT
243: Java-Level JVM Compiler
Interface
•You can trace JVM JIT
activity via this interface.
244: TLS Application-Layer
Protocol Negotiation Extension
•javax.net.ssl package
supports the TLS ALPN.
•This feature rela...
245: Validate JVM Command-
Line Flag Arguments
•For example, some JVM flag
takes an out-of-range value,
and crashes withou...
246: Leverage CPU Instructions
for GHASH and RSA
•Good security with a low
overhead.
246: Leverage CPU Instructions
for GHASH and RSA
•Good security with a low
overhead.
• for SPARC and Intel x64 CPU.
247: Compile for Older Platform
Versions
•javac for older.
248: Make G1 the Default
Garbage Collector
•Oracle says “G1 is good”.
•Huge impact to a operation
by default JVM options.
...
249: OCSP Stapling for TLS
•TLS. Support RFC 6961.
250: Store Interned Strings in
CDS Archives
•Interned String will be stored
in Class-Data Sharing when
G1GC used.
•A histo...
251: Multi-Resolution Images
•A new java.awt.image API for
multi-resolution image.
y
y/2
x/2
x
252: Use CLDR Locale Data by
Default
•Use locale data from the
Unicode Common Locale
Data Repository.
253: Prepare JavaFX UI Controls
& CSS APIs for Modularization
•To clean around JavaFX to
prepare for Project Jigsaw.
254: Compact Strings
•String class diet.
255: Merge Selected Xerces
2.11.0 Updates into JAXP
•To update JAXP from Xerces
2.7.1 to 2.11.0.
256: BeanInfo Annotations
•Replace @beaninfo .
•@interface JavaBean {…}
•@interface BeanProperty {…}
•@interface SwingCont...
257: Update JavaFX/Media to
Newer Version of GStreamer
•Update GStreamer.
•GStreamer: multimedia
framework.
258: HarfBuzz Font-Layout Engine
•Replace OpenType font-
layout engine from ICU to
HarfBuzz.
Important features for me.
•sun.misc.Unsafe alternatives.
•G1GC by default.
•Project Jigsaw.
•JIT compiler is more friendl...
Upcoming SlideShare
Loading in …5
×

JDK9 Features (Summary, 31/Jul/2015) #JJUG

11,295 views

Published on

A summary about JDK9 Features. (31/Jul/2015)
This slide is used for Java Japan User Group LT with beer.

Published in: Technology
  • Be the first to comment

JDK9 Features (Summary, 31/Jul/2015) #JJUG

  1. 1. JDK9 KUBOTA Yuji (@sugarlife) Java Japan User Group LT with b33r 10/Aug/2015
  2. 2. Attention •Depends on OpenJDK project. •This slide provides only the summary for LT. Something may have been changed until General Availability is released. •Drunken Speaker, Drunken LT. Please, don’t be serious :p http://openjdk.java.net/projects/jdk9/ (31/Jul/2015)
  3. 3. Who am I •KUBOTA Yuji (@sugarlife) •icedtea committer (HeapStats) •OpenJDK Contributor •JavaOne Speaker •Hard-hearing person
  4. 4. JDK9 Schedule •2015/12/10: Feature Complete • : Many tests •2016/07/21: Final Release Candidate •2016/09/22: General Availability http://openjdk.java.net/projects/jdk9/
  5. 5. What features will come? 102: Process API Updates 110: HTTP 2 Client 143: Improve Contended Locking 158: Unified JVM Logging 165: Compiler Control 193: Variable Handles 197: Segmented Code Cache 199: Smart Java Compilation, Phase Two 201: Modular Source Code 211: Elide Deprecation Warnings on Import Statements 212: Resolve Lint and Doclint Warnings 213: Milling Project Coin 214: Remove GC Combinations Deprecated in JDK 8 215: Tiered Attribution for javac 216: Process Import Statements Correctly 217: Annotations Pipeline 2.0 219: Datagram Transport Layer Security (DTLS) 220: Modular Run-Time Images 221: Simplified Doclet API 222: jshell: The Java Shell (Read-Eval-Print Loop) 223: New Version-String Scheme 224: HTML5 Javadoc 226: UTF-8 Property Files 227: Unicode 7.0 228: Add More Diagnostic Commands 229: Create PKCS12 Keystores by Default 230: Microbenchmark Suite 231: Remove Launch-Time JRE Version Selection 232: Improve Secure Application Performance 233: Generate Run-Time Compiler Tests Automatically 235: Test Class-File Attributes Generated by javac 236: Parser API for Nashorn 237: Linux/AArch64 Port 240: Remove the JVM TI hprof Agent 241: Remove the jhat Tool 243: Java-Level JVM Compiler Interface 244: TLS Application-Layer Protocol Negotiation Extension 245: Validate JVM Command-Line Flag Arguments 246: Leverage CPU Instructions for GHASH and RSA 247: Compile for Older Platform Versions 248: Make G1 the Default Garbage Collector 249: OCSP Stapling for TLS 250: Store Interned Strings in CDS Archives 251: Multi-Resolution Images 252: Use CLDR Locale Data by Default 253: Prepare JavaFX UI Controls & CSS APIs for Modularization 254: Compact Strings 255: Merge Selected Xerces 2.11.0 Updates into JAXP 256: BeanInfo Annotations 257: Update JavaFX/Media to Newer Version of GStreamer 258: HarfBuzz Font-Layout Engine
  6. 6. What features will come? 102: Process API Updates 110: HTTP 2 Client 143: Improve Contended Locking 158: Unified JVM Logging 165: Compiler Control 193: Variable Handles 197: Segmented Code Cache 199: Smart Java Compilation, Phase Two 201: Modular Source Code 211: Elide Deprecation Warnings on Import Statements 212: Resolve Lint and Doclint Warnings 213: Milling Project Coin 214: Remove GC Combinations Deprecated in JDK 8 215: Tiered Attribution for javac 216: Process Import Statements Correctly 217: Annotations Pipeline 2.0 219: Datagram Transport Layer Security (DTLS) 220: Modular Run-Time Images 221: Simplified Doclet API 222: jshell: The Java Shell (Read-Eval-Print Loop) 223: New Version-String Scheme 224: HTML5 Javadoc 226: UTF-8 Property Files 227: Unicode 7.0 228: Add More Diagnostic Commands 229: Create PKCS12 Keystores by Default 230: Microbenchmark Suite 231: Remove Launch-Time JRE Version Selection 232: Improve Secure Application Performance 233: Generate Run-Time Compiler Tests Automatically 235: Test Class-File Attributes Generated by javac 236: Parser API for Nashorn 237: Linux/AArch64 Port 240: Remove the JVM TI hprof Agent 241: Remove the jhat Tool 243: Java-Level JVM Compiler Interface 244: TLS Application-Layer Protocol Negotiation Extension 245: Validate JVM Command-Line Flag Arguments 246: Leverage CPU Instructions for GHASH and RSA 247: Compile for Older Platform Versions 248: Make G1 the Default Garbage Collector 249: OCSP Stapling for TLS 250: Store Interned Strings in CDS Archives 251: Multi-Resolution Images 252: Use CLDR Locale Data by Default 253: Prepare JavaFX UI Controls & CSS APIs for Modularization 254: Compact Strings 255: Merge Selected Xerces 2.11.0 Updates into JAXP 256: BeanInfo Annotations 257: Update JavaFX/Media to Newer Version of GStreamer 258: HarfBuzz Font-Layout Engine ( ゚д゚ )
  7. 7. Give it a once-over! •This color’s feature is important for ME who develop the product depends on JVM. •This color’s feature is interesting for someone who develop java applications. •Good feature. But not affects on me.
  8. 8. 102: Process API Updates •Do you want information about process? ok, here is.
  9. 9. 110: HTTP 2 Client •Do you want API for HTTP/2 ? ok, here is.
  10. 10. 143: Improve Contended Locking •Good speed for contended java object monitors. •JVM will get a better performance without change of your codes. •But, HeapStats (includes thread monitor) developers may be required hard work.
  11. 11. 158: Unified JVM Logging •Shall we unify the log format of JVM: e.g. compiler, gc, classload, metaspace, etc... •If you develop log parser, watch it. •Xlog[:[<what>][:[<output>][:[<decorat ors>][:<output-options>]]]] •Xlog:gc=debug:file=gc.log:uptimemi llis,pids:filecount=5,filesize=1024
  12. 12. 165: Compiler Control •I WANNA CONTROL COMPILER MORE DETAIL! •You (probably JVM tester) can •add some order when specified method is being compiled (for c1 and c2). • print assembly, set breakpoint, enable compile or not, and more. •change the option sets while run
  13. 13. 193: Variable Handles •sun.misc.Unsafe may be removed. •So we prepare the alternatives. This JEP is the first step for it.
  14. 14. (おまけ) sun.misc.Unsafe 動向 • 6/15-16 に行われた JCP Executive Committee Meeting で隠蔽・削除 に向けた影響や代替方法などの話し合いが行われた • 元々 sun.* 等は Jigsaw(module化) 関係で処遇を決める必要があった • JCP Meeting の議題はここ、Unsafeに関する議事録はここ。 • この代替方法の最初のステップとして先の VarHandles が提案され、つ い最近(7月)に JDK9 に盛り込まれることが決まった • VarHandles Project 詳細 (JVM Language Summit 2014) http://www.oracle.com/technetwork/java/jvmls2014sandoz-2265216.pdf • 今のところは • sun.misc.Unsafe などが deprecated / removed される時期は未明 • sun.misc.Unsafe を含む重要な内部 API はJDK9 では隠蔽のみ、JDK10 で は削除したいという方向に議論が進んでいる (ソース:ML, JEP260) • 代替方法も提案されているが実際に実装が揃うのはこれから • という状況なので、JDK9 で使う方法を含めた具体的な実装はまだこれ からですが、準備は意識した方が良いです。Feature Complete で確認 しましょう :) なお、黒魔術なので仕組みを理解してから使いましょう
  15. 15. 197: Segmented Code Cache •Code cache diet. •JVM will get a better performance without change of your codes.
  16. 16. 199: Smart Java Compilation, Phase Two •sjavac.
  17. 17. 201: Modular Source Code •JDK source code into modules. •A part of Project Jigsaw. •If you read OpenJDK source code, you need to remake your nautical table :p
  18. 18. 211: Elide Deprecation Warnings on Import Statements •Lint warnings is cry-wolf? •javac always show warning when you import statement which include a deprecated method or member. •So resolve it.
  19. 19. 212: Resolve Lint and Doclint Warnings •To clean lint and doclint errors of some JDK components.
  20. 20. 213: Milling Project Coin •Add language changes. •@SafeVargs on private methods • non-overridable executable. •improve try-with-resource • allow effectively final variables to be used as resources. •Allow diamond with anonymous classes if the argument type of the inferred type is denotable. •and more two coins.
  21. 21. 214: Remove GC Combinations Deprecated in JDK 8 •Good bye following GC Combi. •DefNew + CMS •ParNew + SerialOld •DefNew + iCMS •ParNew + iCMS •CMS foreground(s) • UseCMSCompactAtFullCollection • CMSFullGCsBeforeCompaction • UseCMSCollectionPassing
  22. 22. 215: Tiered Attribution for javac •New type checking in javac. •If you have interest in “type” in compiler, you should read this implementation.
  23. 23. 216: Process Import Statements Correctly •Fix javac.
  24. 24. 217: Annotations Pipeline 2.0 •javac again.
  25. 25. 219: Datagram Transport Layer Security (DTLS) •API for DTLS 1.0 (RFC 4347) and DTLS 1.2 (RFC 6347)
  26. 26. 220: Modular Run-Time Images •Restructure the JDK and JRE to accommodate modules. •A main part of Project Jigsaw •Many risks and impacts •no longer contain the files • lib/rt.jar, lib/tools.jar, lib/dt.jar,.. •Class loader of some existing packages will change, and more. •But very useful for many Dev.
  27. 27. 221: Simplified Doclet API •Replace Docklet API (com.sun.javadoc) .
  28. 28. 222: jshell: The Java Shell (Read- Eval-Print Loop) •No need more Test.java! •An interactive tool for Java programming language. •You can use it already at below. •https://jdk9.java.net/download/ •@bitter_fox joined this project. •(Japanese committer)
  29. 29. 223: New Version-String Scheme •Change version-string format. •Security update 2 times + Minor update 1 times •Current • long: 1.8.0_20-b62 • short:8u20 •Proposed • long: 9.1.2+62 • short:9.1.2 • $MAJOR.$MINOR.$SECURITY
  30. 30. 224: HTML5 Javadoc http://www.w3.org/html/logo/
  31. 31. 226: UTF-8 Property Files •You will be enable to use UTF-8 property files.
  32. 32. 227: Unicode 7.0 •You will..( see title.
  33. 33. 228: Add More Diagnostic Commands •Add below commands •print_class_summary (loaded classes) •print_codegenlist (method queued) •print_vm_state •print_uft8pool •datadump_request (heapdump?) •dump_codelist (n-methods) •print_codeblocks (code cache) •set_vmflag
  34. 34. 229: Create PKCS12 Keystores by Default •Improve security.
  35. 35. 230: Microbenchmark Suite •JMH++ •Add a basic suite of microbenchmark to JDK codes.
  36. 36. 231: Remove Launch-Time JRE Version Selection •Remove forgotten options. •“-version:” option •Not “-version” option •“JRE-Version” manifest entry at jar file.
  37. 37. 232: Improve Secure Application Performance •Good speed with a security manager installed.
  38. 38. 233: Generate Run-Time Compiler Tests Automatically •Generate jtreg-compatible automatically for openjdk developers. •If you want to evaluate JVM with new CPU instructions, optimizations, and other enhancements, generated tests should be useful.
  39. 39. 235: Test Class-File Attributes Generated by javac •yes, javac.
  40. 40. 236: Parser API for Nashorn •To get IDE support for Nashorn.
  41. 41. 237: Linux/AArch64 Port •ARM®
  42. 42. 240: Remove the JVM TI hprof Agent •Good bye hprof •See also (alternatives) •OProfile •perf •YourKit •SystemTap (for debug)
  43. 43. 241: Remove the jhat Tool •Good bye jhat •See also (alternatives) •Eclipse MAT
  44. 44. 243: Java-Level JVM Compiler Interface •You can trace JVM JIT activity via this interface.
  45. 45. 244: TLS Application-Layer Protocol Negotiation Extension •javax.net.ssl package supports the TLS ALPN. •This feature relates to HTTP/2 support (JEP110).
  46. 46. 245: Validate JVM Command- Line Flag Arguments •For example, some JVM flag takes an out-of-range value, and crashes without an informative error message. •So fix it.
  47. 47. 246: Leverage CPU Instructions for GHASH and RSA •Good security with a low overhead.
  48. 48. 246: Leverage CPU Instructions for GHASH and RSA •Good security with a low overhead. • for SPARC and Intel x64 CPU.
  49. 49. 247: Compile for Older Platform Versions •javac for older.
  50. 50. 248: Make G1 the Default Garbage Collector •Oracle says “G1 is good”. •Huge impact to a operation by default JVM options. •But I think that all listeners set a configuration to use specified GC. So this change does not impact you. •Really?
  51. 51. 249: OCSP Stapling for TLS •TLS. Support RFC 6961.
  52. 52. 250: Store Interned Strings in CDS Archives •Interned String will be stored in Class-Data Sharing when G1GC used. •A history of a housing •Permanent Gen (JDK6) •Java Heap (JDK7-8) •Class-Data Sharing (JDK9+G1)
  53. 53. 251: Multi-Resolution Images •A new java.awt.image API for multi-resolution image. y y/2 x/2 x
  54. 54. 252: Use CLDR Locale Data by Default •Use locale data from the Unicode Common Locale Data Repository.
  55. 55. 253: Prepare JavaFX UI Controls & CSS APIs for Modularization •To clean around JavaFX to prepare for Project Jigsaw.
  56. 56. 254: Compact Strings •String class diet.
  57. 57. 255: Merge Selected Xerces 2.11.0 Updates into JAXP •To update JAXP from Xerces 2.7.1 to 2.11.0.
  58. 58. 256: BeanInfo Annotations •Replace @beaninfo . •@interface JavaBean {…} •@interface BeanProperty {…} •@interface SwingContainer{…}
  59. 59. 257: Update JavaFX/Media to Newer Version of GStreamer •Update GStreamer. •GStreamer: multimedia framework.
  60. 60. 258: HarfBuzz Font-Layout Engine •Replace OpenType font- layout engine from ICU to HarfBuzz.
  61. 61. Important features for me. •sun.misc.Unsafe alternatives. •G1GC by default. •Project Jigsaw. •JIT compiler is more friendly. •jshell

×