Enviar pesquisa
Carregar
Java 8 from perm gen to metaspace
•
0 gostou
•
545 visualizações
Mohammad Faizan
Seguir
Java 8 from perm gen to metaspace
Leia menos
Leia mais
Educação
Denunciar
Compartilhar
Denunciar
Compartilhar
1 de 6
Baixar agora
Baixar para ler offline
Recomendados
Java 9 Features
Java 9 Features
NexThoughts Technologies
Java11 New Features
Java11 New Features
Haim Michael
Java 10 New Features
Java 10 New Features
Ali BAKAN
OpenJDK-Zulu talk at JEEConf'14
OpenJDK-Zulu talk at JEEConf'14
Ivan Krylov
JDK 9, 10, 11 and Beyond
JDK 9, 10, 11 and Beyond
Simon Ritter
JSR 168 Portal - Overview
JSR 168 Portal - Overview
Vinay Kumar
Moving Towards JDK 12
Moving Towards JDK 12
Simon Ritter
Java 9 preview
Java 9 preview
Ivan Krylov
Recomendados
Java 9 Features
Java 9 Features
NexThoughts Technologies
Java11 New Features
Java11 New Features
Haim Michael
Java 10 New Features
Java 10 New Features
Ali BAKAN
OpenJDK-Zulu talk at JEEConf'14
OpenJDK-Zulu talk at JEEConf'14
Ivan Krylov
JDK 9, 10, 11 and Beyond
JDK 9, 10, 11 and Beyond
Simon Ritter
JSR 168 Portal - Overview
JSR 168 Portal - Overview
Vinay Kumar
Moving Towards JDK 12
Moving Towards JDK 12
Simon Ritter
Java 9 preview
Java 9 preview
Ivan Krylov
uPortal Roadmap
uPortal Roadmap
kweiner
Springboot2 postgresql-jpa-hibernate-crud-example with test
Springboot2 postgresql-jpa-hibernate-crud-example with test
HyukSun Kwon
What's new in Java 11
What's new in Java 11
Michel Schudel
Java 9 Modularity and Project Jigsaw
Java 9 Modularity and Project Jigsaw
Comsysto Reply GmbH
Java 12 - New features in action
Java 12 - New features in action
Marco Molteni
The features of java 11 vs. java 12
The features of java 11 vs. java 12
FarjanaAhmed3
The latest features coming to Java 12
The latest features coming to Java 12
NexSoftsys
Java 9 New Features
Java 9 New Features
Ali BAKAN
Highlights from Java 10, 11 and 12 and Future of Java at Javaland 2019 By Vad...
Highlights from Java 10, 11 and 12 and Future of Java at Javaland 2019 By Vad...
Vadym Kazulkin
Data Base Testing Interview Questions
Data Base Testing Interview Questions
Rita Singh
UFT An advance version of QTP
UFT An advance version of QTP
Rita Singh
Java 8 Overview
Java 8 Overview
Nicola Pedot
JDK 14 Lots of New Features
JDK 14 Lots of New Features
Simon Ritter
JDK-9: Modules and Java Linker
JDK-9: Modules and Java Linker
Bhanu Prakash Gopularam
Java 9
Java 9
Aleksei Bulgak
Pure Java RAD and Scaffolding Tools Race
Pure Java RAD and Scaffolding Tools Race
Baruch Sadogursky
Highlights from Java 10-13 and Future of Java at JCON 2019 by Alukhanov and K...
Highlights from Java 10-13 and Future of Java at JCON 2019 by Alukhanov and K...
Vadym Kazulkin
Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)
Robert Scholte
Exploring Java Heap Dumps (Oracle Code One 2018)
Exploring Java Heap Dumps (Oracle Code One 2018)
Ryan Cuprak
Head toward Java 14 and Java 15 #LINE_DM
Head toward Java 14 and Java 15 #LINE_DM
Yuji Kubota
Java and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystem
Rafael Winterhalter
GlassFish and JavaEE, Today and Future
GlassFish and JavaEE, Today and Future
Alexis Moussine-Pouchkine
Mais conteúdo relacionado
Mais procurados
uPortal Roadmap
uPortal Roadmap
kweiner
Springboot2 postgresql-jpa-hibernate-crud-example with test
Springboot2 postgresql-jpa-hibernate-crud-example with test
HyukSun Kwon
What's new in Java 11
What's new in Java 11
Michel Schudel
Java 9 Modularity and Project Jigsaw
Java 9 Modularity and Project Jigsaw
Comsysto Reply GmbH
Java 12 - New features in action
Java 12 - New features in action
Marco Molteni
The features of java 11 vs. java 12
The features of java 11 vs. java 12
FarjanaAhmed3
The latest features coming to Java 12
The latest features coming to Java 12
NexSoftsys
Java 9 New Features
Java 9 New Features
Ali BAKAN
Highlights from Java 10, 11 and 12 and Future of Java at Javaland 2019 By Vad...
Highlights from Java 10, 11 and 12 and Future of Java at Javaland 2019 By Vad...
Vadym Kazulkin
Data Base Testing Interview Questions
Data Base Testing Interview Questions
Rita Singh
UFT An advance version of QTP
UFT An advance version of QTP
Rita Singh
Java 8 Overview
Java 8 Overview
Nicola Pedot
JDK 14 Lots of New Features
JDK 14 Lots of New Features
Simon Ritter
JDK-9: Modules and Java Linker
JDK-9: Modules and Java Linker
Bhanu Prakash Gopularam
Java 9
Java 9
Aleksei Bulgak
Pure Java RAD and Scaffolding Tools Race
Pure Java RAD and Scaffolding Tools Race
Baruch Sadogursky
Highlights from Java 10-13 and Future of Java at JCON 2019 by Alukhanov and K...
Highlights from Java 10-13 and Future of Java at JCON 2019 by Alukhanov and K...
Vadym Kazulkin
Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)
Robert Scholte
Exploring Java Heap Dumps (Oracle Code One 2018)
Exploring Java Heap Dumps (Oracle Code One 2018)
Ryan Cuprak
Head toward Java 14 and Java 15 #LINE_DM
Head toward Java 14 and Java 15 #LINE_DM
Yuji Kubota
Mais procurados
(20)
uPortal Roadmap
uPortal Roadmap
Springboot2 postgresql-jpa-hibernate-crud-example with test
Springboot2 postgresql-jpa-hibernate-crud-example with test
What's new in Java 11
What's new in Java 11
Java 9 Modularity and Project Jigsaw
Java 9 Modularity and Project Jigsaw
Java 12 - New features in action
Java 12 - New features in action
The features of java 11 vs. java 12
The features of java 11 vs. java 12
The latest features coming to Java 12
The latest features coming to Java 12
Java 9 New Features
Java 9 New Features
Highlights from Java 10, 11 and 12 and Future of Java at Javaland 2019 By Vad...
Highlights from Java 10, 11 and 12 and Future of Java at Javaland 2019 By Vad...
Data Base Testing Interview Questions
Data Base Testing Interview Questions
UFT An advance version of QTP
UFT An advance version of QTP
Java 8 Overview
Java 8 Overview
JDK 14 Lots of New Features
JDK 14 Lots of New Features
JDK-9: Modules and Java Linker
JDK-9: Modules and Java Linker
Java 9
Java 9
Pure Java RAD and Scaffolding Tools Race
Pure Java RAD and Scaffolding Tools Race
Highlights from Java 10-13 and Future of Java at JCON 2019 by Alukhanov and K...
Highlights from Java 10-13 and Future of Java at JCON 2019 by Alukhanov and K...
Apache Maven supports all Java (JokerConf 2018)
Apache Maven supports all Java (JokerConf 2018)
Exploring Java Heap Dumps (Oracle Code One 2018)
Exploring Java Heap Dumps (Oracle Code One 2018)
Head toward Java 14 and Java 15 #LINE_DM
Head toward Java 14 and Java 15 #LINE_DM
Semelhante a Java 8 from perm gen to metaspace
Java and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystem
Rafael Winterhalter
GlassFish and JavaEE, Today and Future
GlassFish and JavaEE, Today and Future
Alexis Moussine-Pouchkine
Tech Days 2010
Tech Days 2010
Luqman Shareef
Java 7 Dolphin manjula kollipara
Java 7 Dolphin manjula kollipara
Manjula Kollipara
Java Webinar #12: "Java Versions and Features: Since JDK 8 to 16"
Java Webinar #12: "Java Versions and Features: Since JDK 8 to 16"
GlobalLogic Ukraine
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK.v1.0.20191009
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK.v1.0.20191009
Firmansyah, SCJP, OCEWCD, OCEWSD, TOGAF, OCMJEA, CEH
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK
Firmansyah, SCJP, OCEWCD, OCEWSD, TOGAF, OCMJEA, CEH
Jakarta EE 最前線 - Jakarta EEの現在、ロードマップなど
Jakarta EE 最前線 - Jakarta EEの現在、ロードマップなど
オラクルエンジニア通信
Java EE 6 & Spring: A Lover's Quarrel
Java EE 6 & Spring: A Lover's Quarrel
Mauricio "Maltron" Leal
Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)
Robert Scholte
Integrating tomcat with apache
Integrating tomcat with apache
govindraj8787
Apache tomcat
Apache tomcat
Abhishek Kesharwani
Apache Tomcat 8 Application Server
Apache Tomcat 8 Application Server
mohamedmoharam
What's Expected in Java 7
What's Expected in Java 7
Gal Marder
Java EE 6 & GlassFish v3: Paving path for the future
Java EE 6 & GlassFish v3: Paving path for the future
Arun Gupta
Java EE 6 : Paving The Path For The Future
Java EE 6 : Paving The Path For The Future
IndicThreads
Java 7: Quo vadis?
Java 7: Quo vadis?
Michal Malohlava
Java dev mar_2021_keynote
Java dev mar_2021_keynote
Suyash Joshi
Java Version History.pdf
Java Version History.pdf
SudhanshiBakre1
The Eclipse Transformer Project
The Eclipse Transformer Project
Jakarta_EE
Semelhante a Java 8 from perm gen to metaspace
(20)
Java and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystem
GlassFish and JavaEE, Today and Future
GlassFish and JavaEE, Today and Future
Tech Days 2010
Tech Days 2010
Java 7 Dolphin manjula kollipara
Java 7 Dolphin manjula kollipara
Java Webinar #12: "Java Versions and Features: Since JDK 8 to 16"
Java Webinar #12: "Java Versions and Features: Since JDK 8 to 16"
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK.v1.0.20191009
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK.v1.0.20191009
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK
Comparison between Oracle JDK, Oracle OpenJDK, and Red Hat OpenJDK
Jakarta EE 最前線 - Jakarta EEの現在、ロードマップなど
Jakarta EE 最前線 - Jakarta EEの現在、ロードマップなど
Java EE 6 & Spring: A Lover's Quarrel
Java EE 6 & Spring: A Lover's Quarrel
Java 9 and the impact on Maven Projects (JavaOne 2016)
Java 9 and the impact on Maven Projects (JavaOne 2016)
Integrating tomcat with apache
Integrating tomcat with apache
Apache tomcat
Apache tomcat
Apache Tomcat 8 Application Server
Apache Tomcat 8 Application Server
What's Expected in Java 7
What's Expected in Java 7
Java EE 6 & GlassFish v3: Paving path for the future
Java EE 6 & GlassFish v3: Paving path for the future
Java EE 6 : Paving The Path For The Future
Java EE 6 : Paving The Path For The Future
Java 7: Quo vadis?
Java 7: Quo vadis?
Java dev mar_2021_keynote
Java dev mar_2021_keynote
Java Version History.pdf
Java Version History.pdf
The Eclipse Transformer Project
The Eclipse Transformer Project
Mais de Mohammad Faizan
Colloquium Report
Colloquium Report
Mohammad Faizan
Jdbc basic features
Jdbc basic features
Mohammad Faizan
Tutorial c#
Tutorial c#
Mohammad Faizan
SOFTWARE TESTING UNIT-4
SOFTWARE TESTING UNIT-4
Mohammad Faizan
Software maintenance Unit5
Software maintenance Unit5
Mohammad Faizan
Hibernate using jpa
Hibernate using jpa
Mohammad Faizan
Jvm internal detail
Jvm internal detail
Mohammad Faizan
Unit3 Software engineering UPTU
Unit3 Software engineering UPTU
Mohammad Faizan
Unit2 Software engineering UPTU
Unit2 Software engineering UPTU
Mohammad Faizan
hibernate with JPA
hibernate with JPA
Mohammad Faizan
Allama Iqbal shiqwa with meaning
Allama Iqbal shiqwa with meaning
Mohammad Faizan
Web tech chapter 1 (1)
Web tech chapter 1 (1)
Mohammad Faizan
Mdm intro-chapter1
Mdm intro-chapter1
Mohammad Faizan
Hill climbing
Hill climbing
Mohammad Faizan
Coda file system tahir
Coda file system tahir
Mohammad Faizan
Chapter30 (1)
Chapter30 (1)
Mohammad Faizan
Ai4 heuristic2
Ai4 heuristic2
Mohammad Faizan
Chapter30
Chapter30
Mohammad Faizan
Mais de Mohammad Faizan
(18)
Colloquium Report
Colloquium Report
Jdbc basic features
Jdbc basic features
Tutorial c#
Tutorial c#
SOFTWARE TESTING UNIT-4
SOFTWARE TESTING UNIT-4
Software maintenance Unit5
Software maintenance Unit5
Hibernate using jpa
Hibernate using jpa
Jvm internal detail
Jvm internal detail
Unit3 Software engineering UPTU
Unit3 Software engineering UPTU
Unit2 Software engineering UPTU
Unit2 Software engineering UPTU
hibernate with JPA
hibernate with JPA
Allama Iqbal shiqwa with meaning
Allama Iqbal shiqwa with meaning
Web tech chapter 1 (1)
Web tech chapter 1 (1)
Mdm intro-chapter1
Mdm intro-chapter1
Hill climbing
Hill climbing
Coda file system tahir
Coda file system tahir
Chapter30 (1)
Chapter30 (1)
Ai4 heuristic2
Ai4 heuristic2
Chapter30
Chapter30
Último
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
National Information Standards Organization (NISO)
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
misteraugie
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
sanyamsingh5019
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
EduSkills OECD
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
PECB
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Sapana Sha
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
Sapna Thakur
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
TechSoup
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Krashi Coaching
microwave assisted reaction. General introduction
microwave assisted reaction. General introduction
Maksud Ahmed
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
RaunakKeshri1
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
Jayanti Pande
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
Association for Project Management
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
dawncurless
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
chloefrazer622
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
Maestría en Comunicación Digital Interactiva - UNR
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
SoniaTolstoy
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
Admir Softic
Último
(20)
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
microwave assisted reaction. General introduction
microwave assisted reaction. General introduction
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
Java 8 from perm gen to metaspace
1.
4/21/2016 Java 8: From PermGen to Metaspace https://www.javacodegeeks.com/2013/02/java8frompermgentometaspace.html 1/6 Java 8: From PermGen to Metaspace As you may be aware, the JDK 8 Early Access is now available for download. This allows Java developers to experiment with some of the new language and runtime features of Java 8. One of these features is the complete removal of the Permanent Generation (PermGen) space which has been announced by Oracle since the release of JDK 7. Interned strings, for example, have already been removed from the PermGen space since JDK 7. The JDK 8 release finalizes its decommissioning. This article will share the information that we found so far on the PermGen successor: Metaspace. We will also compare the runtime behavior of the HotSpot 1.7 vs. HotSpot 1.8 (b75) when executing a Java program “leaking” class metadata objects. The final specifications, tuning flags and documentation around Metaspace should be available once Java 8 is officially released. Metaspace: A new memory space is born The JDK 8 HotSpot JVM is now using native memory for the representation of class metadata and is called Metaspace; similar to the Oracle JRockit and IBM JVM’s. The good news is that it means no more java.lang.OutOfMemoryError: PermGen space problems and no need for you to tune and monitor this memory space anymore…not so fast. While this change is invisible by default, we will show you next that you will still need to worry about the class metadata memory footprint. Please also keep in mind that this new feature does not magically eliminate class and classloader memory leaks. You will need to track down these problems using a different approach and by learning the new naming convention. I recommend that you read the PermGen removal summary and comments from Jon on this subject. In summary: PermGen space situation This memory space is completely removed. The PermSize and MaxPermSize JVM arguments are ignored and a warning is issued if present at startup. Metaspace memory allocation model Most allocations for the class metadata are now allocated out of native memory. The klasses that were used to describe class metadata have been removed. Metaspace capacity
2.
4/21/2016 Java 8: From PermGen to Metaspace https://www.javacodegeeks.com/2013/02/java8frompermgentometaspace.html 2/6 By default class metadata allocation is limited by the amount of available native memory (capacity will of course depend if you use a 32bit JVM vs. 64bit along with OS virtual memory availability). A new flag is available (MaxMetaspaceSize), allowing you to limit the amount of native memory used for class metadata. If you don’t specify this flag, the Metaspace will dynamically resize depending of the application demand at runtime. Metaspace garbage collection Garbage collection of the dead classes and classloaders is triggered once the class metadata usage reaches the “MaxMetaspaceSize”. Proper monitoring & tuning of the Metaspace will obviously be required in order to limit the frequency or delay of such garbage collections. Excessive Metaspace garbage collections may be a symptom of classes, classloaders memory leak or inadequate sizing for your application. Java heap space impact Some miscellaneous data has been moved to the Java heap space. This means you may observe an increase of the Java heap space following a future JDK 8 upgrade. Metaspace monitoring Metaspace usage is available from the HotSpot 1.8 verbose GC log output. Jstat & JVisualVM have not been updated at this point based on our testing with b75 and the old PermGen space references are still present. Enough theory now, let’s see this new memory space in action via our leaking Java program… PermGen vs. Metaspace runtime comparison In order to better understand the runtime behavior of the new Metaspace memory space, we created a class metadata leaking Java program. You can download the source here. The following scenarios will be tested: Run the Java program using JDK 1.7 in order to monitor & deplete the PermGen memory space set at 128 MB. Run the Java program using JDK 1.8 (b75) in order to monitor the dynamic increase and garbage collection of the new Metaspace memory space. Run the Java program using JDK 1.8 (b75) in order to simulate the depletion of the Metaspace by setting the MaxMetaspaceSize value at 128 MB. JDK 1.7 @64bit – PermGen depletion
3.
4/21/2016 Java 8: From PermGen to Metaspace https://www.javacodegeeks.com/2013/02/java8frompermgentometaspace.html 3/6 Java program with 50K configured iterations Java heap space of 1024 MB Java PermGen space of 128 MB (XX:MaxPermSize=128m) As you can see form JVisualVM, the PermGen depletion was reached after loading about 30K+ classes. We can also see this depletion from the program and GC output. 1Class metadata leak simulator Now let’s execute the program using the HotSpot JDK 1.8 JRE. JDK 1.8 @64bit – Metaspace dynamic resize Java program with 50K configured iterations Java heap space of 1024 MB Java Metaspace space: unbounded (default)
4.
4/21/2016 Java 8: From PermGen to Metaspace https://www.javacodegeeks.com/2013/02/java8frompermgentometaspace.html 4/6 As you can see from the verbose GC output, the JVM Metaspace did expand dynamically from 20 MB up to 328 MB of reserved native memory in order to honor the increased class metadata memory footprint from our Java program. We could also observe garbage collection events in the attempt by the JVM to destroy any dead class or classloader object. Since our Java program is leaking, the JVM had no choice but to dynamically expand the Metaspace memory space. The program was able to run its 50K of iterations with no OOM event and loaded 50K+ Classes. Let’s move to our last testing scenario. JDK 1.8 @64bit – Metaspace depletion Java program with 50K configured iterations Java heap space of 1024 MB Java Metaspace space: 128 MB (XX:MaxMetaspaceSize=128m)
5.
4/21/2016 Java 8: From PermGen to Metaspace https://www.javacodegeeks.com/2013/02/java8frompermgentometaspace.html 5/6 As you can see form JVisualVM, the Metaspace depletion was reached after loading about 30K+ classes; very similar to the run with the JDK 1.7. We can also see this from the program and GC output. Another interesting observation is that the native memory footprint reserved was twice as much as the maximum size specified. This may indicate some opportunities to fine tune the Metaspace resize policy, if possible, in order to avoid native memory waste. Now find below the Exception we got from the Java program output. 1Class metadata leak simulator Done! As expected, capping the Metaspace at 128 MB like we did for the baseline run with JDK 1.7 did not allow us to complete the 50K iterations of our program. A new OOM error was thrown by the JVM. The above OOM event was thrown by the JVM from the Metaspace following a memory allocation failure. #metaspace.cpp
6.
4/21/2016 Java 8: From PermGen to Metaspace https://www.javacodegeeks.com/2013/02/java8frompermgentometaspace.html 6/6 Final words I hope you appreciated this early analysis and experiment with the new Java 8 Metaspace. The current observations definitely indicate that proper monitoring & tuning will be required in order to stay away from problems such as excessive Metaspace GC or OOM conditions triggered from our last testing scenario. Future articles may include performance comparisons in order to identify potential performance improvements associated with this new feature.
Baixar agora