title: Java Mission Control Heap Profile
body: <p>I am playing with the <strong>new</strong> Java Mission Control Profiler that is coming with the Java 7u40 and I cannot make it to <strong>profile allocation and collect object statistics</strong>. No matter what I do, I cannot see any statistics in the Memory -> <strong>Object Statistics</strong> window.</p>
  
  <p>The following command starts the collection:</p>
  
  <pre><code>jcmd &lt;pid&gt; JFR.start duration=60s settings=profile filename=alloc-prof.jfr
  </code></pre>
  
  <p>The <a href="http://docs.oracle.com/javase/7/docs/technotes/guides/jfr/toc.html">Java Mission Control documentation</a> does not mention any specific options to enable object profiling. I have tried to create my own profile and set :</p>
  
  <pre><code>  &lt;flag name="heap-statistics-enabled" label="Heap Statistics"&gt;true&lt;/flag&gt;
    &lt;flag name="allocation-profiling-enabled" label="Allocation Profiling"&gt;true&lt;/flag&gt;
  </code></pre>
  
  <p>But still no Object Statistics are collected.</p>