/
persistence.xml
34 lines (29 loc) · 1.73 KB
/
persistence.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?xml version="1.0" encoding="UTF-8"?>
<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">
<persistence-unit name="myFirstPersistenceUnit">
<properties>
<property name="hibernate.archive.autodetection" value="class" />
<property name="hibernate.show_sql" value="true" />
<!-- <property name="hibernate.connection.driver_class" value="org.postgresql.Driver" /> -->
<property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver" />
<!-- <property name="hibernate.connection.username" value="postgres" /> -->
<property name="hibernate.connection.username" value="root" />
<!-- <property name="hibernate.connection.password" value="postgres" /> -->
<property name="hibernate.connection.password" value="toor" />
<!-- <property name="hibernate.connection.url" value="jdbc:postgresql://127.0.0.1:5432/iti_note" /> -->
<property name="hibernate.connection.url" value="jdbc:mysql://127.0.0.1:3306/iti_note" />
<!-- <property name="hibernate.dialect" value="org.hibernate.dialect.PostgreSQLDialect" /> -->
<property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect" />
<property name="hibernate.c3p0.min_size" value="5" />
<property name="hibernate.c3p0.max_size" value="20" />
<property name="hibernate.c3p0.timeout" value="1800" />
<property name="hibernate.c3p0.max_statements" value="50" />
<!-- <property name="hibernate.c3p0.idle_test_period" value="3000" /> -->
<property name="hibernate.hbm2ddl.auto" value="update" />
</properties>
</persistence-unit>
</persistence>