Advertisement
zacmaster

persistence.xml

Oct 10th, 2018
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 1.64 KB | None | 0 0
  1. <!--
  2.  ~ Hibernate, Relational Persistence for Idiomatic Java
  3.  ~
  4.  ~ License: GNU Lesser General Public License (LGPL), version 2.1 or later.
  5.  ~ See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
  6.  -->
  7. <persistence xmlns="http://java.sun.com/xml/ns/persistence"
  8.             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  9.             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
  10.             version="2.0">
  11.  
  12.     <persistence-unit name="org.hibernate.jpa">
  13.      
  14.         <class>com.grupo3.rest.persistencia.entidades.Usuario</class>      
  15.          <class>com.grupo3.rest.persistencia.entidades.Alumno</class>  
  16.           <class>com.grupo3.rest.persistencia.entidades.Contacto</class>    
  17.           <class>com.grupo3.rest.persistencia.entidades.Curso</class>  
  18.           <class>com.grupo3.rest.persistencia.entidades.Area</class>  
  19.        
  20.  
  21.         <properties>
  22.              <property name="javax.persistence.jdbc.driver" value="com.mysql.jdbc.Driver" />
  23.             <property name="javax.persistence.jdbc.url" value="jdbc:mysql://localhost:3306/tp" />
  24.             <property name="javax.persistence.jdbc.user" value="root" /> <!-- "api" para hostear en aws -->
  25.             <property name="javax.persistence.jdbc.password" value="root" />
  26.  
  27.             <property name="hibernate.dialect" value="org.hibernate.dialect.MySQL5InnoDBDialect"/>
  28.             <property name="hibernate.show_sql" value="true" />
  29.             <property name="hibernate.hbm2ddl.auto" value="update" />
  30.         </properties>
  31.  
  32.     </persistence-unit>
  33.  
  34. </persistence>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement