title: Error parsing the persistence.xml(org.hibernate.MappingException)
body: <p>I am using JPA and I tried to put my configuration data in the <strong>persistence.xml</strong> file.
  But when I run the app, the error is as follows:</p>
  
  <pre><code>[hibernatetool] org.hibernate.MappingException: invalid configuration
  [hibernatetool] org.xml.sax.SAXParseException: Document is invalid: no grammar found.
  </code></pre>
  
  <p>And I googled it. It seems to say I have missed the <em>DOCTYPE</em> part. Like: </p>
  
  <pre><code>&lt;!DOCTYPE hibernate-configuration PUBLIC
          "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
          "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd"&gt;
  </code></pre>
  
  <p>So I tried to add the missing DOCTYPE part. But new question comes. WHAT should I add?</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;persistence xmlns="http://java.sun.com/xml/ns/persistence"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
      http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
      version="1.0"&gt;
      &lt;persistence-unit name="helloworld"&gt;
          &lt;property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver" /&gt;
          &lt;property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/db" /&gt;
          &lt;property name="hibernate.connection.username" value="*****" /&gt;
          &lt;property name="hibernate.connection.password" value="*****" /&gt;
          &lt;property name="hibernate.dialect" value="org.hibernate.dialect.MySQLInnoDBDialect" /&gt;
  
      &lt;/persistence-unit&gt;
  &lt;/persistence&gt;
  </code></pre>
  
  <p><strong>PS:</strong>
  I have downdloaded several jpa sample projects and checked the associated persistence.xml files but found that they are all absent of the DOCTYPE part. </p>
  
  <p>Is the DOCTYPE part necessary, I have to ask, because so many code samples are absent from it.</p>
  
  <p>The solution for my problem seems to be:
  <em>what should I put for the DOCTYPE part.</em></p>