Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
    Bookmark Topic Watch Topic
  • New Topic

Cannot Open Connection problem in Hibernate + MySQL + Tomcat

 
Saravanamuthu Krishnan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi
I am a beginner to hibernate. I have prefered to use hibernate with tomcat and mysql.

I have done all things that are all to integrate hibernate and mysql. But i got an error.

org.hibernate.exception.GenericJDBCException: Cannot open connection

<hibernate-configuration>
<session-factory>
<property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
<property name="hibernate.connection.url">jdbc:mysql://localhost:3306/hibernatetutorial</property>
<property name="hibernate.connection.username">root</property>
<property name="hibernate.connection.password">syncro</property>
<property name="hibernate.connection.pool_size">10</property>
<property name="show_sql">true</property>
<property name="dialect">org.hibernate.dialect.MySQLDialect</property>

<mapping resource="contact.hbm.xml"/>
</session-factory>
</hibernate-configuration>
 
    Bookmark Topic Watch Topic
  • New Topic