Set up database connection pool (#234)

Set up database connection pool
This commit is contained in:
Shicong Huang
2019-08-29 16:12:28 -04:00
committed by GitHub
parent b5ef99a8f8
commit 487b695a10
8 changed files with 233 additions and 23 deletions
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8" ?>
<persistence xmlns="http://xmlns.jcp.org/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence
http://xmlns.jcp.org/xml/ns/persistence/persistence_2_2.xsd"
version="2.2">
<persistence-unit name="nomulus" transaction-type="RESOURCE_LOCAL">
<description>
Persistence unit for the Nomulus Cloud SQL database.
</description>
<provider>org.hibernate.jpa.HibernatePersistenceProvider</provider>
<!--
All JPA entities must be enumerated here. JPA does not support auto detection.
Note that Hibernate's auto detection functionality (hibernate.archive.autodection)
does not meet our needs. It only scans archives, not the 'classes' folders. So we
are left with two options:
* Move tests to another (sub)project. This is not a big problem, but feels unnatural.
* Use Hibernate's ServiceRegistry for bootstrapping (not JPA-compliant)
-->
<class>google.registry.model.domain.DomainBase</class>
<class>google.registry.schema.tmch.ClaimsList</class>
<!-- TODO(weiminyu): check out application-layer validation. -->
<validation-mode>NONE</validation-mode>
</persistence-unit>
</persistence>