title: What is the Metadata GC Threshold and how do I tune it?
body: <p>In an application I have the following <code>-verbose:gc</code></p>
  
  <pre><code>[GC (Metadata GC Threshold)  8530310K-&gt;2065630K(31574016K), 0.3831399 secs]
  [Full GC (Metadata GC Threshold)  2065630K-&gt;2053217K(31574016K), 3.5927870 secs]
  [GC (Metadata GC Threshold)  8061486K-&gt;2076192K(31574016K), 0.0096316 secs]
  [Full GC (Metadata GC Threshold)  2076192K-&gt;2055722K(31574016K), 0.9376524 secs]
  [GC (Metadata GC Threshold)  8765230K-&gt;2100440K(31574016K), 0.0150190 secs]
  [Full GC (Metadata GC Threshold)  2100440K-&gt;2077052K(31574016K), 4.1662779 secs]
  </code></pre>
  
  <p>What is this <em>"Metadata GC threshold"</em> and how to I reduce it.  Note: while the Full GC spends a long time cleaning up, it does not actually clean up much, i.e. it would be better if it didn't do this.</p>