Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

JDK 11 ClassLoader Hierarchy Details Coming to JCMD

DZone's Guide to

JDK 11 ClassLoader Hierarchy Details Coming to JCMD

An extremely useful addition is coming to the jcmd tool in regards to the ClassLoader hierarchy. Read this post to learn more!

· Java Zone ·
Free Resource

Verify, standardize, and correct the Big 4 + more– name, email, phone and global addresses – try our Data Quality APIs now at Melissa Developer Portal!

I've been a fan of the diagnostic command-line tool jcmd, since hearing about jcmd at JavaOne 2012. I've used this tool extensively since then and have blogged multiple times about this tool.

After numerous years of developing with Java, it's my opinion that the ClassLoader is the source of some of the most difficult defects encountered during development and debugging. Given this observation and my interest injcmd, I am very interested in JDK-8203682 ["Add jcmd 'VM.classloaders' command to print out ClassLoader hierarchy details"].

The "Description" for JDK-8203682 states, "It would be helpful, as a complement to VM.classloader_stats, to have a command to print out the ClassLoader hierarchy and ClassLoader details." In other words, this command is to be added tojcmd and would include a display of ClassLoaders in a hierarchical fashion, similar to the way classes are displayed byjcmd's VM.class_hierarchy command.

JDK-8203682 shows its "Status" as " Resolved" and its "Fix Version" as " 11". JDK-8203682 contains three text file attachments that depict the output of jcmd <pid> VM.classloaders: example-with-classes.txt, example-with-classes-verbose.txt, and example-with-reflection-and-noinflation.txt. Additional information is available in the announcement of the change set and in the change set itself.

When dealing with ClassLoader-related issues in Java, any details can be helpful. The addition of theVM.classloaders command to jcmdwill make this command-line tool even more valuable and insightful.

Developers! Quickly and easily gain access to the tools and information you need! Explore, test and combine our data quality APIs at Melissa Developer Portal – home to tools that save time and boost revenue. Our APIs verify, standardize, and correct the Big 4 + more – name, email, phone and global addresses – to ensure accurate delivery, prevent blacklisting and identify risks in real-time.

Topics:
java ,jcmd ,jdk 11 ,feature ,command line interface ,tool

Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}