SlideShare a Scribd company logo
JavaOne 2016
Java SE Feedback
KUBOTA Yuji @sugarlife <kubota.yuji@gmail.com>
NTT OSS Center
2016/Oct/15
Copyright©2016 NTT corporation
2
• 公開予定
•写真 撮 Twitter (#jjug #j1jp)
!
•質問 #jjug #j1jp @sugarlife
諸注意
Copyright©2016 NTT corporation
3
Who I am
Copyright©2016 NTT corporation
KUBOTA Yuji (@sugarlife), hard-of-hearing
Senior Expert in NTT
OpenJDK Author (ykubota)
IcedTea Committer
4
Copyright©2016 NTT corporation
https://github.com/HeapStats/heapstats
https://twitter.com/skrb/status/778119996736172033
https://www.flickr.com/photos/yosshi2007/29315365363/in/albu
m-72157672916952542/
5
6
Copyright©2016 NTT corporation
今日 方針
7
う い
Copyright©2016 NTT corporation
頑張 け い 通
愛媛県 亀老山 望 来島海峡大橋 , METI, Creative Commons Attribution 4.0 International License (CC BY 4.0)
8
•Future Java SE
• JDK 9
•Project Jigsaw / JShell / Reactive (Flow API)
• JDK 10 or later
•Project Valhalla / Project Panama
•Changes required for Java 9
Agenda:
Copyright©2016 NTT corporation
今回 題
Future Java SE
Copyright©2016 NTT corporation
9
10
JDK 9
JDK9 release reschedule to 2017/3/23 (2015/12/9)
Feature Complete (2016/5/26)
JDK 9 is not (yet) Feature Complete (2016/6/10)
JDK 9 release reschedule to 2017/7/23 (2016/9/20)
JDK 10
Not scheduled
Schedule
Copyright©2016 NTT corporation
JavaOne 開催直前 JDK 9 再延長
NEW!
11
今年 JDK 9 セ ョン
Copyright©2016 NTT corporation
多く 良 あ け状態
12
•JDK 9
• Project Jigsaw
•Project Kulla (JShell)
• Reactive Streams Specification (The Flow API)
•JDK 10 or later
• Project Valhalla
• Project Panama
主 新機能
Copyright©2016 NTT corporation
HTTP/2 Client jcmd 拡張 あ
13
•JAR Hell
•Lack / Conflict / Unsafe internal update
•New container: Module
•Dependency / Exportation / Version
•Separate standard libraries: Module JDK
•jlink: Make Custom JRE
Project Jigsaw
Copyright©2016 NTT corporation
必要最低限 抑え う依 公開先 定義可能
14
• Directives in module-package.java
• requires public <module>
• requires static <module>
• exports private <package>
• @bitter_fox 記事 参考
• Many command line options
• 例: -mp -> -p
Difference from JavaOne 2015
Copyright©2016 NTT corporation
-J-Duser.language=en 確認 う
transitive
15
Project Kulla (JShell)
Copyright©2016 NTT corporation
客様 中 コ 様 い い
16
•REPL for Java
•Alternatives for Exercise.java ?
•CLI framework
• https://github.com/YaSuenag/jmxclient
Project Kulla (JShell)
Copyright©2016 NTT corporation
将来的 jcmd jmx 触 い
$ jshell
| Welcome to JShell -- Version 9-ea
| For an introduction type: /help intro
17
•Reactive programming
•依 関係( ) 関数 組合
•Reactive Streams
•非 期 標準 様 ン
• 制御( 溢 防止) 相互互換性 確保
• https://community.oracle.com/docs/DOC-1006738
Reactive Streams (The Flow API)
Copyright©2016 NTT corporation
@okapies 資料 @making 資料 解 い
18
•Value types will be simple
•Value types
•Generic Specialization
•Enhanced volatiles
•今年 発表 (キ ンセ )
• JVMLS 2016 あ (映像1, 映像2, 映像3)
Project Valhalla
Copyright©2016 NTT corporation
型 仲良く う いう
19
•Pure data aggregates that (ideally) should
have no ancillary overhead
•Value types is simple
•Identity lead pointer
•Pointer lead to indirection
•Indirection lead to suffering
Why Project Valhalla
Copyright©2016 NTT corporation
ン あ
20
•A better way to do native interop
•Foreign APIs
•Vectors
•(Array 2.0)
•今年 大 変更 (経過 順調 う)
• JVMLS 2016 (映像1, 映像2, 映像3)
Project Panama
Copyright©2016 NTT corporation
Native(あ い CPU) 仲良く う いう
21
•1000s of vector instructions on x86
• Intel intrinsic instructions
• AVX/AVX2: 〜380
• AVX-512: 〜3800
•How to bind to particular machine
instructions in the implementation?
Why Project Panama
Copyright©2016 NTT corporation
計算機 (CPU) 使い切
22
Changes required for Java 9
主 出典:
openjdk.java.net/projects/jdk9
JavaOne 2016 Sessions:
Preparing for JDK 9:
The Sharp Edges [CON6171]
JDK 9 Language, Tooling,
and Library Features [CON2497]
Copyright©2016 NTT corporation
23
Changes required for Java 9
大体影響 あ う
Copyright©2016 NTT corporation
24
•大半 内部 API セ 化(隠蔽)
•JDK 9 コ ン ョン 回避 可能
•広く使わ い 物(Critical API) 代替 用
意 公開
•jdeps 使 影響あ 確認 推奨
• 特 Multi-Release JAR files (JEP 238, JDK 9)
JEP 260: Encapsulate most internal APIs
Copyright©2016 NTT corporation
特 利用 影響受け い 確認
25
•Critical APIs (keep public)
• sun.misc.Unsafe
•sun.misc.{Signal,SignalHandler}
• sun.misc.Cleaner
• sun.reflect.Reflection::getCallerClass
• sun.reflect.ReflectionFactory
• 以外 削除(隠蔽)
JEP 260: Encapsulate most internal APIs
Copyright©2016 NTT corporation
Critical APIs JDK 10 以降 削除 可能性あ
26
•Endorsed-standards override and Extension
mechanism has been dropped
•-Xbootclasspath, -Xbootclasspath/p,
-Dsun.boot.class.path has been removed
• 参考: 検索方法(JDK 8)
• AppClassLoader URLClassLoader ン ン
無く (継承 い)等 影響
Change class loaders mechanism in JEP
261: Module System
Copyright©2016 NTT corporation
Module 化 配置 推奨 いう流
27
•JDK 8 削除済 or 非推奨 ョン
使 場合 警告 セ 出 け
(無視 起動 )
•JDK 9 場合 起動
•JDK 8 非推奨 ョン 削除
(例: Perm 世代 ョン)
Unrecognized VM options fail to start
Copyright©2016 NTT corporation
warning: ignoring option XXX; support was removed in 8.0
28
•-source / -target 3 世代前 サ
•JDK 9 場合 1.6 1.5 drop
JEP 182: Policy for Retiring javac –
source and –target options
Copyright©2016 NTT corporation
JDK 9 ビ JDK 5 動 人 居 い ?
29
•-version: コ ン ン ョン削除
•-version く : 付く方
•JAR Manifest JRE-Version 削除
JEP 231: Remove Launch-Time JRE
Version Selection
Copyright©2016 NTT corporation
起動時 ョン指定 く
30
•1.8.0_101-b14
•1.$MAJOR.0_$MINOR-b$BUILD
•9.1.2+62
•$MAJOR.$MINOR.$SECURITY+$BUILD
•java.specification.version
•1.8 9-ea (GA 後 9 )
JEP 223: New Version String Scheme
Copyright©2016 NTT corporation
ョン表記 決 打 読 込 影響
31
•JDK 構造 ァ 変更
JEP 220: Modular Run-Time Images
Copyright©2016 NTT corporation
ァ 等 決 打 読 込 影響
32
•JEP 289: Deprecate the Applet API
• java.applet.{AppletStub,Applet,AudioClip,Apple
tContext}
• javax.swing.JApplet
•Fix insecure issues
•Remove support for serialized applets (JDK-8074161)
• No longer allow non-strict JNLP Parsing (JDK-8075605)
Follow the evolution of WEB
Copyright©2016 NTT corporation
Web 動向(NPAPI) セキュ 面 非推奨化 流
33
•JEP 229: Create PKCS12 Keystores by Default
•keystore type JKS PKCS12 変更
•JEP 288: Disable SHA-1 Certificates
• X.509 証明書 ン SHA-1 署 利用 い
場合 注意
Improve encryption for security
Copyright©2016 NTT corporation
コ いう 利用 証明書 問題
34
•従来 JVM 廃止 ョン
変更
• く使わ い ョン 変更例
• -XX:+PrintGCDetails -Xloggc:gc.log.`date +%Y-
%m-%d_%H-%M-%S` -XX:+PrintGCTimeStamps
• -Xlog:gc*=debug:gc.log.%t:time,level
• -Xlog:[<selection>]:[<output>]:[<decorators>]
JEP 158: Unified JVM Logging
JEP 271: Unified GC Logging
Copyright©2016 NTT corporation
Parser 系 い い全滅
35
JEP 158: Unified JVM Logging
JEP 271: Unified GC Logging
Copyright©2016 NTT corporation
JJUG CCC 2016 Fall 楽 !(通 言 い)
36
Changes required for Java 9
範囲 狭い 刺 痛い
Copyright©2016 NTT corporation
37
• java.util.logging.LogManager
#{add|remove}PropertyChangeListener
• java.util.jar.Pack200.{Packer|Unpacker}#
{add|remove}PropertyChangeListener
• com.sun.security.auth.callback.DialogCal
lbackHandle
Remove deprecated APIs in JEP 162:
Prepare for Modularization
Copyright©2016 NTT corporation
JDK 8 非推奨 い API 削除
38
• Toolkit implementers (JDK-8037739)
• java.awt.peer package
• java.awt.dnd.peer package
• Unsupported Apple APIs
• com.apple.eawt, com.apple.eio (JEP 272)
• com.apple.concurrent (JDK-8148187)
• AppleScript scripting engine (JDK-8143404)
• com.sun.codec.jpeg (JDK-8038838)
Removed APIs
Copyright©2016 NTT corporation
関係 多い
39
•UnsupportedOperationException 返
• JDK-7059085 (非公開)
•Java SE 1.2 時代 非推奨
•Thread.stop() 残
• いえ inconsistent state
留 処理 危険 伴う 注意
Thread.stop(Throwable) throw UOE
Copyright©2016 NTT corporation
前 ョン い
40
• Arrays.asList(x).toArrays() returns Object[]
(JDK-6260652)
• 今 配列 ン(clone) 返 い
• JDK 9 Object[] 返
Behavior changed API
Copyright©2016 NTT corporation
JEP 関係 い API 挙動変更
41
• _ 1文 禁止 (JDK-8061549)
• 排除 い
• JLS §15.27.1. Lambda Parameters (Java 8)
Disallow _ as a one-character identifier
by JEP 213: Milling Project Coin
Copyright©2016 NTT corporation
いい 前 授け う
42
•String 化 一環 内部 (value)
型 char[] byte[] 変更
•1文 毎 2byte(UTF-16) 1byte 扱
え 1byte 以外 従来通
• 回避 内部 直接
受け渡 意外 多い 注意
The value field of String is no longer
char[] by JEP 254: Compact Strings
Copyright©2016 NTT corporation
文 列 性能 永遠 課題
43
•RMI HTTP proxy
•RMI/JRMP HTTP tunneling
実装 削除 (JDK-8155978)
The entire HTTP proxying mechanism of RMI
deprecated in JDK 8 will be removed
Copyright©2016 NTT corporation
前 ョン 非推奨化 削除 一環
44
• 以下 組合
• DefNew + CMS / iCMS
•ParNew + SerialOld / iCMS
• CMS foreground(s)
• -XX:+UseCMSCompactAtFullCollection
• -XX:+CMSFullGCsBeforeCompaction
• -XX:+UseCMSCollectionPassing
JEP 214: Remove GC Combinations
Deprecated in JDK 8
Copyright©2016 NTT corporation
JDK 8 時点 非推奨 非サ
45
• Parallel GC G1 GC
•-XX:+UseParallel(Old)GC 従来通
•CMS GC 非推奨化 進 い
(JEP 291)
JEP 248: Make G1 the Default Garbage
Collector
Copyright©2016 NTT corporation
G1 GC 資料(JJUG CCC 2015 Fall) 参考
46
•JEP 240: hprof
• コ 残 Oracle JDK 提供 い
•JVM TI BCI コ あ 非公式扱い
• heapdump jmap/jcmd, profiler VisualVM等
•JEP 241: jhat
• くコ 残 experimental 除去
•大半 experimental
Good bye tools by JEP 240 and JEP 241
Copyright©2016 NTT corporation
[PR] heap profiler & visualizer HeapStats !
47
•jcmd 機能強化
•Java Day Tokyo 2016 @YaSuenag 講演
•JavaOne 2016 講演
•jcmd 自体 Java Casual #2 !
•http://java-casual.connpass.com/event/42461/
JEP 228: Add More Diagnostic Commands
Copyright©2016 NTT corporation
jcmd 不幸 減 広 い
48
JEP 228: Add More Diagnostic Commands
Copyright©2016 NTT corporation
Domain Num. Abstract
PerfCounter 1 - Performance Counter
ManagementAgent 4 +1 JMX agent
Thread 1 - Thread dump
GC 8 +2
-1
Heap / GC / Finalization
VM 15 +8 Runtime info. (log/native mem/flag/etc.)
Compiler 7 - JIT Compiler
JVMTI 2 - JVMTI agent
Removed GC.rotate_log to VM domain
一覧 感
49
影響 あ う 変更
Copyright©2016 NTT corporation
影響度合い 掴 い
• Windows 32 Client VM 廃止
• Unicode CLDR (JEP 252)
• -Djava.locale.providers=JRE,SPI 従来通
• JavaDB (Apache Derby) 廃止 (JDK-8004716)
• Property file UTF-8 利用可能(JEP 226)
• ResourceBundle API UTF-8 読込
• StringBuilder::append 生成 コ 変更 (JEP 280)
• invokedynamic 利用 JDK library function ぶ う
50
い
@sugarlife
kubota.yuji@gmail.com
Copyright©2016 NTT corporation

More Related Content

PPTX
Jdk9で変更になる(かも知れない)jvmオプションの標準設定
PDF
JavaOne 2015 JDK Update (Jigsaw) #j1jp
PDF
Versatil Javaチューニング
PPTX
Java EE パフォーマンスTips #glassfish_jp
PDF
WildFly Swarm - Rightsize Your Java EE Apps
PDF
日本OpenStackユーザ会第40回勉強会 Nova最新動向
PDF
Jakarta EE 9 と これから
PDF
商用ミドルウェアのPuppet化で気を付けたい5つのこと
Jdk9で変更になる(かも知れない)jvmオプションの標準設定
JavaOne 2015 JDK Update (Jigsaw) #j1jp
Versatil Javaチューニング
Java EE パフォーマンスTips #glassfish_jp
WildFly Swarm - Rightsize Your Java EE Apps
日本OpenStackユーザ会第40回勉強会 Nova最新動向
Jakarta EE 9 と これから
商用ミドルウェアのPuppet化で気を付けたい5つのこと

What's hot (20)

PDF
今年はJava進化の年!今知っておくべき新しいJava
PDF
WildFly Swarmではじめる「パーツとしてのJavaEE」
PDF
CPUから見たG1GC
PDF
Advanced database monitoring in modern java
PDF
Keycloak で SSO #渋谷java
PPTX
Kubernetes環境に対する性能試験(Kubernetes Novice Tokyo #2 発表資料)
PPTX
Spring I/O 2015 報告
PDF
Java SE 再入門
PDF
Logicadの秒間16万リクエストをさばく広告入札システムにおける、gRPCの活用事例
PDF
Jjug 20140430 gradle_basic
PPTX
OSSで作るOpenStack監視システム
PDF
JakartaOne Livestream Japan 2020
PDF
Yahoo! JAPANが実践するOpenStackと大規模環境でのコンテナ利用 #devsumi
PPTX
microprofile
PDF
#jjug_ccc #ccc_f1 広告システム刷新の舞台裏 - PHPからJavaに変えてみました
PDF
Reactive Webアプリケーション - そしてSpring 5へ #jjug_ccc #ccc_ef3
PPTX
OpenStack Summit Austin 2016 参加報告 - OpenStack最新情報セミナー 2016年5月
PDF
JDK:新しいリリースモデル解説 @ 熊本・福岡
PDF
20160521 大規模映像配信サービスの Java8による全面リニューアルの裏側
PDF
CDI2.0アップデート&クックブック #JavaDayTokyo #jdt2016_4c
今年はJava進化の年!今知っておくべき新しいJava
WildFly Swarmではじめる「パーツとしてのJavaEE」
CPUから見たG1GC
Advanced database monitoring in modern java
Keycloak で SSO #渋谷java
Kubernetes環境に対する性能試験(Kubernetes Novice Tokyo #2 発表資料)
Spring I/O 2015 報告
Java SE 再入門
Logicadの秒間16万リクエストをさばく広告入札システムにおける、gRPCの活用事例
Jjug 20140430 gradle_basic
OSSで作るOpenStack監視システム
JakartaOne Livestream Japan 2020
Yahoo! JAPANが実践するOpenStackと大規模環境でのコンテナ利用 #devsumi
microprofile
#jjug_ccc #ccc_f1 広告システム刷新の舞台裏 - PHPからJavaに変えてみました
Reactive Webアプリケーション - そしてSpring 5へ #jjug_ccc #ccc_ef3
OpenStack Summit Austin 2016 参加報告 - OpenStack最新情報セミナー 2016年5月
JDK:新しいリリースモデル解説 @ 熊本・福岡
20160521 大規模映像配信サービスの Java8による全面リニューアルの裏側
CDI2.0アップデート&クックブック #JavaDayTokyo #jdt2016_4c
Ad

Similar to JavaOne 2016 Java SE Feedback #jjug #j1jp (20)

PDF
Prepare for Java 9 #jjug
PDF
Javaヂカラ #Java最新動向 -Java 11 の新機能やOracle Code One 2018 発の最新技術トレンドを一気にキャッチアップ-
PDF
より速く より運用しやすく 進化し続けるJVM(Java Developers Summit Online 2023 発表資料)
PPTX
Let's Start Contributing to OpenJDK from Today!(Oracle Groundbreakers APAC Vi...
PDF
10のJava9で変わるJava8の嫌なとこ!
PDF
JDK9 新機能 (日本語&ショートバージョン) #jjug
PDF
20170303 java9 hadoop
PDF
OpenJDKのコミッタってどんなことしたらなったの?解決してきた技術課題の事例から見えてくる必要な知識と技術(JJUG CCC 2023 Spring)
PDF
OpenJDK コミュニティに参加してみよう #jjug
PPTX
Java 9 and Future #jjug
PDF
Oracle code one 2018 報告会概要
PPTX
Java 17直前!オレ流OpenJDK「の」開発環境(Open Source Conference 2021 Online/Kyoto 発表資料)
PDF
Migration Guide from Java 8 to Java 11 #jjug
PDF
Head toward Java 15 and Java 16
PDF
Java によるクラウドネイティブ の実現に向けて
KEY
関ジャバ JavaOne Tokyo 2012報告会
PDF
Head toward Java 16 (Night Seminar Edition)
PDF
JJUG CCC 2014 Spring IBM SDK for Java 8の全貌 #jjug_ccc #ccc_r57
PDF
What is java_se_7
PPTX
Metaspace
Prepare for Java 9 #jjug
Javaヂカラ #Java最新動向 -Java 11 の新機能やOracle Code One 2018 発の最新技術トレンドを一気にキャッチアップ-
より速く より運用しやすく 進化し続けるJVM(Java Developers Summit Online 2023 発表資料)
Let's Start Contributing to OpenJDK from Today!(Oracle Groundbreakers APAC Vi...
10のJava9で変わるJava8の嫌なとこ!
JDK9 新機能 (日本語&ショートバージョン) #jjug
20170303 java9 hadoop
OpenJDKのコミッタってどんなことしたらなったの?解決してきた技術課題の事例から見えてくる必要な知識と技術(JJUG CCC 2023 Spring)
OpenJDK コミュニティに参加してみよう #jjug
Java 9 and Future #jjug
Oracle code one 2018 報告会概要
Java 17直前!オレ流OpenJDK「の」開発環境(Open Source Conference 2021 Online/Kyoto 発表資料)
Migration Guide from Java 8 to Java 11 #jjug
Head toward Java 15 and Java 16
Java によるクラウドネイティブ の実現に向けて
関ジャバ JavaOne Tokyo 2012報告会
Head toward Java 16 (Night Seminar Edition)
JJUG CCC 2014 Spring IBM SDK for Java 8の全貌 #jjug_ccc #ccc_r57
What is java_se_7
Metaspace
Ad

More from Yuji Kubota (20)

PDF
Head toward Java 14 and Java 15 #LINE_DM
PDF
Head toward Java 14 and Java 15
PDF
オンライン会議と音声認識
PDF
Head toward Java 13 and Java 14 #jjug
PDF
Catch up Java 12 and Java 13
PDF
Introduction to Java 11: Support and JVM Features #jjug
PDF
Java 10でぼくたちの生活はどう変わるの?
PPTX
Project Jigsaw #kanjava
PPTX
Secrets of Rock Star Developers (and How to Become One!) [CON7615] (Yuji KUBO...
PDF
Unified JVM Logging
PDF
jcmd #javacasual
PDF
Garbage First Garbage Collection (G1 GC) #jjug_ccc #ccc_cd6
PDF
OpenJDK トラブルシューティング #javacasual
PDF
HeapStats @ Seasar Conference 2015 LT
PDF
JDK9 Features (Summary, 31/Jul/2015) #JJUG
PDF
HeapStats: Introduction and Technical Preview
PDF
JVM のいろはにほ #javajo
PDF
HeapStats: Troubleshooting with Serviceability and the New Runtime Monitoring...
PDF
Concurrent Mark-Sweep Garbage Collection #jjug_ccc
PDF
楽して JVM を学びたい #jjug
Head toward Java 14 and Java 15 #LINE_DM
Head toward Java 14 and Java 15
オンライン会議と音声認識
Head toward Java 13 and Java 14 #jjug
Catch up Java 12 and Java 13
Introduction to Java 11: Support and JVM Features #jjug
Java 10でぼくたちの生活はどう変わるの?
Project Jigsaw #kanjava
Secrets of Rock Star Developers (and How to Become One!) [CON7615] (Yuji KUBO...
Unified JVM Logging
jcmd #javacasual
Garbage First Garbage Collection (G1 GC) #jjug_ccc #ccc_cd6
OpenJDK トラブルシューティング #javacasual
HeapStats @ Seasar Conference 2015 LT
JDK9 Features (Summary, 31/Jul/2015) #JJUG
HeapStats: Introduction and Technical Preview
JVM のいろはにほ #javajo
HeapStats: Troubleshooting with Serviceability and the New Runtime Monitoring...
Concurrent Mark-Sweep Garbage Collection #jjug_ccc
楽して JVM を学びたい #jjug

JavaOne 2016 Java SE Feedback #jjug #j1jp

  • 1. JavaOne 2016 Java SE Feedback KUBOTA Yuji @sugarlife <kubota.yuji@gmail.com> NTT OSS Center 2016/Oct/15 Copyright©2016 NTT corporation
  • 2. 2 • 公開予定 •写真 撮 Twitter (#jjug #j1jp) ! •質問 #jjug #j1jp @sugarlife 諸注意 Copyright©2016 NTT corporation
  • 3. 3 Who I am Copyright©2016 NTT corporation KUBOTA Yuji (@sugarlife), hard-of-hearing Senior Expert in NTT OpenJDK Author (ykubota) IcedTea Committer
  • 7. 7 う い Copyright©2016 NTT corporation 頑張 け い 通 愛媛県 亀老山 望 来島海峡大橋 , METI, Creative Commons Attribution 4.0 International License (CC BY 4.0)
  • 8. 8 •Future Java SE • JDK 9 •Project Jigsaw / JShell / Reactive (Flow API) • JDK 10 or later •Project Valhalla / Project Panama •Changes required for Java 9 Agenda: Copyright©2016 NTT corporation 今回 題
  • 9. Future Java SE Copyright©2016 NTT corporation 9
  • 10. 10 JDK 9 JDK9 release reschedule to 2017/3/23 (2015/12/9) Feature Complete (2016/5/26) JDK 9 is not (yet) Feature Complete (2016/6/10) JDK 9 release reschedule to 2017/7/23 (2016/9/20) JDK 10 Not scheduled Schedule Copyright©2016 NTT corporation JavaOne 開催直前 JDK 9 再延長 NEW!
  • 11. 11 今年 JDK 9 セ ョン Copyright©2016 NTT corporation 多く 良 あ け状態
  • 12. 12 •JDK 9 • Project Jigsaw •Project Kulla (JShell) • Reactive Streams Specification (The Flow API) •JDK 10 or later • Project Valhalla • Project Panama 主 新機能 Copyright©2016 NTT corporation HTTP/2 Client jcmd 拡張 あ
  • 13. 13 •JAR Hell •Lack / Conflict / Unsafe internal update •New container: Module •Dependency / Exportation / Version •Separate standard libraries: Module JDK •jlink: Make Custom JRE Project Jigsaw Copyright©2016 NTT corporation 必要最低限 抑え う依 公開先 定義可能
  • 14. 14 • Directives in module-package.java • requires public <module> • requires static <module> • exports private <package> • @bitter_fox 記事 参考 • Many command line options • 例: -mp -> -p Difference from JavaOne 2015 Copyright©2016 NTT corporation -J-Duser.language=en 確認 う transitive
  • 15. 15 Project Kulla (JShell) Copyright©2016 NTT corporation 客様 中 コ 様 い い
  • 16. 16 •REPL for Java •Alternatives for Exercise.java ? •CLI framework • https://github.com/YaSuenag/jmxclient Project Kulla (JShell) Copyright©2016 NTT corporation 将来的 jcmd jmx 触 い $ jshell | Welcome to JShell -- Version 9-ea | For an introduction type: /help intro
  • 17. 17 •Reactive programming •依 関係( ) 関数 組合 •Reactive Streams •非 期 標準 様 ン • 制御( 溢 防止) 相互互換性 確保 • https://community.oracle.com/docs/DOC-1006738 Reactive Streams (The Flow API) Copyright©2016 NTT corporation @okapies 資料 @making 資料 解 い
  • 18. 18 •Value types will be simple •Value types •Generic Specialization •Enhanced volatiles •今年 発表 (キ ンセ ) • JVMLS 2016 あ (映像1, 映像2, 映像3) Project Valhalla Copyright©2016 NTT corporation 型 仲良く う いう
  • 19. 19 •Pure data aggregates that (ideally) should have no ancillary overhead •Value types is simple •Identity lead pointer •Pointer lead to indirection •Indirection lead to suffering Why Project Valhalla Copyright©2016 NTT corporation ン あ
  • 20. 20 •A better way to do native interop •Foreign APIs •Vectors •(Array 2.0) •今年 大 変更 (経過 順調 う) • JVMLS 2016 (映像1, 映像2, 映像3) Project Panama Copyright©2016 NTT corporation Native(あ い CPU) 仲良く う いう
  • 21. 21 •1000s of vector instructions on x86 • Intel intrinsic instructions • AVX/AVX2: 〜380 • AVX-512: 〜3800 •How to bind to particular machine instructions in the implementation? Why Project Panama Copyright©2016 NTT corporation 計算機 (CPU) 使い切
  • 22. 22 Changes required for Java 9 主 出典: openjdk.java.net/projects/jdk9 JavaOne 2016 Sessions: Preparing for JDK 9: The Sharp Edges [CON6171] JDK 9 Language, Tooling, and Library Features [CON2497] Copyright©2016 NTT corporation
  • 23. 23 Changes required for Java 9 大体影響 あ う Copyright©2016 NTT corporation
  • 24. 24 •大半 内部 API セ 化(隠蔽) •JDK 9 コ ン ョン 回避 可能 •広く使わ い 物(Critical API) 代替 用 意 公開 •jdeps 使 影響あ 確認 推奨 • 特 Multi-Release JAR files (JEP 238, JDK 9) JEP 260: Encapsulate most internal APIs Copyright©2016 NTT corporation 特 利用 影響受け い 確認
  • 25. 25 •Critical APIs (keep public) • sun.misc.Unsafe •sun.misc.{Signal,SignalHandler} • sun.misc.Cleaner • sun.reflect.Reflection::getCallerClass • sun.reflect.ReflectionFactory • 以外 削除(隠蔽) JEP 260: Encapsulate most internal APIs Copyright©2016 NTT corporation Critical APIs JDK 10 以降 削除 可能性あ
  • 26. 26 •Endorsed-standards override and Extension mechanism has been dropped •-Xbootclasspath, -Xbootclasspath/p, -Dsun.boot.class.path has been removed • 参考: 検索方法(JDK 8) • AppClassLoader URLClassLoader ン ン 無く (継承 い)等 影響 Change class loaders mechanism in JEP 261: Module System Copyright©2016 NTT corporation Module 化 配置 推奨 いう流
  • 27. 27 •JDK 8 削除済 or 非推奨 ョン 使 場合 警告 セ 出 け (無視 起動 ) •JDK 9 場合 起動 •JDK 8 非推奨 ョン 削除 (例: Perm 世代 ョン) Unrecognized VM options fail to start Copyright©2016 NTT corporation warning: ignoring option XXX; support was removed in 8.0
  • 28. 28 •-source / -target 3 世代前 サ •JDK 9 場合 1.6 1.5 drop JEP 182: Policy for Retiring javac – source and –target options Copyright©2016 NTT corporation JDK 9 ビ JDK 5 動 人 居 い ?
  • 29. 29 •-version: コ ン ン ョン削除 •-version く : 付く方 •JAR Manifest JRE-Version 削除 JEP 231: Remove Launch-Time JRE Version Selection Copyright©2016 NTT corporation 起動時 ョン指定 く
  • 30. 30 •1.8.0_101-b14 •1.$MAJOR.0_$MINOR-b$BUILD •9.1.2+62 •$MAJOR.$MINOR.$SECURITY+$BUILD •java.specification.version •1.8 9-ea (GA 後 9 ) JEP 223: New Version String Scheme Copyright©2016 NTT corporation ョン表記 決 打 読 込 影響
  • 31. 31 •JDK 構造 ァ 変更 JEP 220: Modular Run-Time Images Copyright©2016 NTT corporation ァ 等 決 打 読 込 影響
  • 32. 32 •JEP 289: Deprecate the Applet API • java.applet.{AppletStub,Applet,AudioClip,Apple tContext} • javax.swing.JApplet •Fix insecure issues •Remove support for serialized applets (JDK-8074161) • No longer allow non-strict JNLP Parsing (JDK-8075605) Follow the evolution of WEB Copyright©2016 NTT corporation Web 動向(NPAPI) セキュ 面 非推奨化 流
  • 33. 33 •JEP 229: Create PKCS12 Keystores by Default •keystore type JKS PKCS12 変更 •JEP 288: Disable SHA-1 Certificates • X.509 証明書 ン SHA-1 署 利用 い 場合 注意 Improve encryption for security Copyright©2016 NTT corporation コ いう 利用 証明書 問題
  • 34. 34 •従来 JVM 廃止 ョン 変更 • く使わ い ョン 変更例 • -XX:+PrintGCDetails -Xloggc:gc.log.`date +%Y- %m-%d_%H-%M-%S` -XX:+PrintGCTimeStamps • -Xlog:gc*=debug:gc.log.%t:time,level • -Xlog:[<selection>]:[<output>]:[<decorators>] JEP 158: Unified JVM Logging JEP 271: Unified GC Logging Copyright©2016 NTT corporation Parser 系 い い全滅
  • 35. 35 JEP 158: Unified JVM Logging JEP 271: Unified GC Logging Copyright©2016 NTT corporation JJUG CCC 2016 Fall 楽 !(通 言 い)
  • 36. 36 Changes required for Java 9 範囲 狭い 刺 痛い Copyright©2016 NTT corporation
  • 37. 37 • java.util.logging.LogManager #{add|remove}PropertyChangeListener • java.util.jar.Pack200.{Packer|Unpacker}# {add|remove}PropertyChangeListener • com.sun.security.auth.callback.DialogCal lbackHandle Remove deprecated APIs in JEP 162: Prepare for Modularization Copyright©2016 NTT corporation JDK 8 非推奨 い API 削除
  • 38. 38 • Toolkit implementers (JDK-8037739) • java.awt.peer package • java.awt.dnd.peer package • Unsupported Apple APIs • com.apple.eawt, com.apple.eio (JEP 272) • com.apple.concurrent (JDK-8148187) • AppleScript scripting engine (JDK-8143404) • com.sun.codec.jpeg (JDK-8038838) Removed APIs Copyright©2016 NTT corporation 関係 多い
  • 39. 39 •UnsupportedOperationException 返 • JDK-7059085 (非公開) •Java SE 1.2 時代 非推奨 •Thread.stop() 残 • いえ inconsistent state 留 処理 危険 伴う 注意 Thread.stop(Throwable) throw UOE Copyright©2016 NTT corporation 前 ョン い
  • 40. 40 • Arrays.asList(x).toArrays() returns Object[] (JDK-6260652) • 今 配列 ン(clone) 返 い • JDK 9 Object[] 返 Behavior changed API Copyright©2016 NTT corporation JEP 関係 い API 挙動変更
  • 41. 41 • _ 1文 禁止 (JDK-8061549) • 排除 い • JLS §15.27.1. Lambda Parameters (Java 8) Disallow _ as a one-character identifier by JEP 213: Milling Project Coin Copyright©2016 NTT corporation いい 前 授け う
  • 42. 42 •String 化 一環 内部 (value) 型 char[] byte[] 変更 •1文 毎 2byte(UTF-16) 1byte 扱 え 1byte 以外 従来通 • 回避 内部 直接 受け渡 意外 多い 注意 The value field of String is no longer char[] by JEP 254: Compact Strings Copyright©2016 NTT corporation 文 列 性能 永遠 課題
  • 43. 43 •RMI HTTP proxy •RMI/JRMP HTTP tunneling 実装 削除 (JDK-8155978) The entire HTTP proxying mechanism of RMI deprecated in JDK 8 will be removed Copyright©2016 NTT corporation 前 ョン 非推奨化 削除 一環
  • 44. 44 • 以下 組合 • DefNew + CMS / iCMS •ParNew + SerialOld / iCMS • CMS foreground(s) • -XX:+UseCMSCompactAtFullCollection • -XX:+CMSFullGCsBeforeCompaction • -XX:+UseCMSCollectionPassing JEP 214: Remove GC Combinations Deprecated in JDK 8 Copyright©2016 NTT corporation JDK 8 時点 非推奨 非サ
  • 45. 45 • Parallel GC G1 GC •-XX:+UseParallel(Old)GC 従来通 •CMS GC 非推奨化 進 い (JEP 291) JEP 248: Make G1 the Default Garbage Collector Copyright©2016 NTT corporation G1 GC 資料(JJUG CCC 2015 Fall) 参考
  • 46. 46 •JEP 240: hprof • コ 残 Oracle JDK 提供 い •JVM TI BCI コ あ 非公式扱い • heapdump jmap/jcmd, profiler VisualVM等 •JEP 241: jhat • くコ 残 experimental 除去 •大半 experimental Good bye tools by JEP 240 and JEP 241 Copyright©2016 NTT corporation [PR] heap profiler & visualizer HeapStats !
  • 47. 47 •jcmd 機能強化 •Java Day Tokyo 2016 @YaSuenag 講演 •JavaOne 2016 講演 •jcmd 自体 Java Casual #2 ! •http://java-casual.connpass.com/event/42461/ JEP 228: Add More Diagnostic Commands Copyright©2016 NTT corporation jcmd 不幸 減 広 い
  • 48. 48 JEP 228: Add More Diagnostic Commands Copyright©2016 NTT corporation Domain Num. Abstract PerfCounter 1 - Performance Counter ManagementAgent 4 +1 JMX agent Thread 1 - Thread dump GC 8 +2 -1 Heap / GC / Finalization VM 15 +8 Runtime info. (log/native mem/flag/etc.) Compiler 7 - JIT Compiler JVMTI 2 - JVMTI agent Removed GC.rotate_log to VM domain 一覧 感
  • 49. 49 影響 あ う 変更 Copyright©2016 NTT corporation 影響度合い 掴 い • Windows 32 Client VM 廃止 • Unicode CLDR (JEP 252) • -Djava.locale.providers=JRE,SPI 従来通 • JavaDB (Apache Derby) 廃止 (JDK-8004716) • Property file UTF-8 利用可能(JEP 226) • ResourceBundle API UTF-8 読込 • StringBuilder::append 生成 コ 変更 (JEP 280) • invokedynamic 利用 JDK library function ぶ う