title: No PersistenceProvider specified in EntityManagerFactory configuration
body: <p>I am using Spring + JPA + Hibernate in an application.I am facing below issue while jettty web server starts(during initialization)</p>
  
  <pre><code>org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.dao.annotation.PersistenceExceptionTranslationPostProcessor#0': Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [commonApplicationContext.xml]: Invocation of init method failed; nested exception is java.lang.IllegalArgumentException: No PersistenceProvider specified in EntityManagerFactory configuration, and chosen PersistenceUnitInfo does not specify a provider class name either
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:532)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:461)
      at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:295)
      at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
  </code></pre>
  
  <p>My configuration file are below.</p>
  
  <p><strong><em>commonApplicationContext.xml--></em></strong></p>
  
  <pre><code>&lt;context:component-scan base-package="com.test.common.dao.*" /&gt;
  
      &lt;context:annotation-config /&gt;
  
      &lt;!--tx:annotation-driven transaction-manager="defaultTransactionManager"/--&gt;
  
      &lt;bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean"&gt;
          &lt;property name="persistenceUnitName" value="common"/&gt;
          &lt;property name="persistenceXmlLocation" value="classpath:META-INF/persistence.xml" /&gt;
          &lt;property name="packagesToScan" value="com.test.common.dao.entity"/&gt;
      &lt;/bean&gt;
  
      &lt;bean id="transactionManager" class="org.springframework.orm.jpa.JpaTransactionManager"&gt;
          &lt;property name="entityManagerFactory" ref="entityManagerFactory"/&gt;
      &lt;/bean&gt;
  
      &lt;bean class="org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor"/&gt;
  </code></pre>
  
  <p><strong>persistence.xml --></strong></p>
  
  <pre><code>&lt;persistence-unit name="common" transaction-type="RESOURCE_LOCAL"&gt;
           &lt;provider&gt;org.hibernate.ejb.HibernatePersistence&lt;/provider&gt;
           &lt;properties&gt;
               &lt;property name="hibernate.ejb.autodetection" value="class"/&gt;
               &lt;property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/test?zeroDateTimeBehavior=convertToNull"/&gt;
               &lt;property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/&gt;
               &lt;property name="hibernate.connection.username" value="root"/&gt;
               &lt;property name="hibernate.connection.password" value="root"/&gt;
               &lt;property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/&gt;
               &lt;property name="hibernate.connection.provider_class" value="org.hibernate.connection.C3P0ConnectionProvider" /&gt;
               &lt;property name="hibernate.c3p0.min_size" value="20"/&gt;
               &lt;property name="hibernate.c3p0.initial_Pool_Size" value="20"/&gt;
               &lt;property name="hibernate.c3p0.max_size" value="100"/&gt;
               &lt;property name="hibernate.c3p0.timeout" value="120"/&gt;
               &lt;property name="hibernate.c3p0.max_statements" value="50"/&gt;
               &lt;property name="hibernate.c3p0.idle_test_period" value="3000"/&gt;
               &lt;property name="hibernate.show_sql" value="true"/&gt;
           &lt;/properties&gt;
       &lt;/persistence-unit&gt;
  </code></pre>