title: Split 1GB Xml file using Java
body: <p>I have a 1GB Xml file, how can I split it into well-formed, smaller size Xml files using Java ?</p>
  
  <p>Here is an example:</p>
  
  <pre><code>&lt;records&gt;
    &lt;record id="001"&gt;
      &lt;name&gt;john&lt;/name&gt;
    &lt;/record&gt;
   ....
  &lt;/records&gt;
  </code></pre>
  
  <p>Thanks.</p>