Advertisement
Guest User

hibernate.cfg

a guest
Feb 28th, 2016
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 1.26 KB | None | 0 0
  1. <?xml version='1.0' encoding='utf-8'?>
  2. <!DOCTYPE hibernate-configuration PUBLIC
  3.        "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
  4.        "http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
  5.  
  6. <hibernate-configuration>
  7.  
  8.     <session-factory>
  9.  
  10.         <!-- Database connection settings -->
  11.         <property name="connection.driver_class">com.mysql.jdbc.Driver</property>
  12.         <property name="connection.url">jdbc:mysql://localhost:3306/bd_vraptor</property>
  13.         <property name="connection.username">root</property>
  14.         <property name="connection.password"></property>
  15.  
  16.  
  17.        
  18.  
  19.  
  20.         <!-- SQL dialect -->
  21.         <property name="dialect">org.hibernate.dialect.MySQL5InnoDBDialect</property>
  22.  
  23.         <!-- Enable Hibernate's automatic session context management -->
  24.         <property name="current_session_context_class">thread</property>
  25.  
  26.         <!-- Disable the second-level cache -->
  27.         <property name="cache.provider_class">org.hibernate.cache.internal.NoCacheProvider</property>
  28.  
  29.         <!-- Echo all executed SQL to stdout -->
  30.         <property name="show_sql">true</property>
  31.  
  32.         <!-- Drop and re-create the database schema on startup -->
  33.         <property name="hbm2ddl.auto">update</property>
  34.  
  35.         <mapping class="com.vraptor.model.Empresa" />
  36.  
  37.  
  38.  
  39.     </session-factory>
  40.  
  41. </hibernate-configuration>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement