I recently upgraded java version from 1.6 to 1.8. After migrating to java 1.8, the metaspace memory consumption increases with time (observed this through JConsole.) Also with every web page access, the metaspace size increases. So,
Is there any way I can forcefully clean up Metaspace?
Is there any way I can check what all goes in Metaspace and increases metaspace size?
Which GC (SerialGC, G1, ConcMarkSweep) efficiently cleans up Metaspace & what JVM VM configurations I should use for GC?
What is the minimal RAM java 1.8 requires for correct metaspace operations? In my case, its limited to 256M RAM with equal amount of swap size on a miniature linux box.
If we limit the metaspace size using XX:MaxMetaSpaceSize, JVM raises outofmemory:metaspace condition.