As seen in the screenshot here, 0 live objects, 9 allocated objects. What's the difference between a live and an allocated object ?
The number of allocated objects is not the number of objects not yet reclaimed by the garbage collector. Rather, it is the number of objects created since application start, or since a reset of the "Collected Results Buffer" in VisualVM (there is a button in the memory profiler view to reset the collected results buffer).
The live objects are those objects that haven't been reclaimed by the garbage collector; this may include objects that are unreachable, and will definitely include objects that are still in use by the application.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.