• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Tim Cooke
  • Jeanne Boyarsky
  • Liutauras Vilda
Sheriffs:
  • Frank Carver
  • Henry Wong
  • Ron McLeod
Saloon Keepers:
  • Tim Moores
  • Frits Walraven
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Himai Minh

Visualization of Heap Memory In java

 
Ranch Hand
Posts: 33
Eclipse IDE Flex Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is there any way to see how many objects are created in/on Heap memory in java
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The JVM has APIs for debugging and profiling, and the current version of Sun Java 6 includes a nice tool called JVisualVM which can show you a lot of information about what's happening in running Java programs. It can show exactly how much memory running Java programs are using, for example. I don't know if it can show exactly how many objects of what types are created, but maybe it can. You should be able to start this tool by typing in "jvisualvm" in a command prompt window.
 
Rajesh Tarte
Ranch Hand
Posts: 33
Eclipse IDE Flex Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does same kind of functionality available in 1.5

Thanks
 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

You can use Jmap for creating the memory dump by providing the process id for java process which is running your program and then you can use eclipse memory analyser tool/plug-in to analyse the memory dump.
This will give you all the details you are looking for. But you will need to have patience in analysing dump and need to understand how to spot an issue.

Regards,
Ashutosh
 
Skool. Stay in. Smartness. Tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic