Browse Source

Ninja: Fix H2 database connection for tests

Keith R. Gustafson 9 years ago
parent
commit
8d410b5635

+ 7 - 0
frameworks/Java/ninja-standalone/pom.xml

@@ -52,6 +52,13 @@
             <artifactId>h2</artifactId>
             <artifactId>h2</artifactId>
             <version>1.3.174</version>
             <version>1.3.174</version>
         </dependency>
         </dependency>
+
+        <dependency>
+            <groupId>xml-apis</groupId>
+            <artifactId>xml-apis</artifactId>
+            <version>1.4.01</version>
+        </dependency>
+
     </dependencies>
     </dependencies>
 
 
     <build>
     <build>

+ 4 - 8
frameworks/Java/ninja-standalone/src/main/resources/META-INF/persistence.xml

@@ -21,15 +21,11 @@
 
 
                 <!-- Connection Pooling settings -->
                 <!-- Connection Pooling settings -->
                 <property name="hibernate.connection.provider_class" value="org.hibernate.hikaricp.internal.HikariCPConnectionProvider" />
                 <property name="hibernate.connection.provider_class" value="org.hibernate.hikaricp.internal.HikariCPConnectionProvider" />
-                <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect" />
                 <property name="hibernate.cache.use_query_cache" value="false" />
                 <property name="hibernate.cache.use_query_cache" value="false" />
-                <property name="hibernate.hikari.minimumIdle" value="256" />
-                <property name="hibernate.hikari.maximumPoolSize" value="256" />
-                <property name="hibernate.hikari.idleTimeout" value="30000" />
-                <property name="hibernate.hikari.dataSourceClassName" value="com.mysql.jdbc.jdbc2.optional.MysqlDataSource" />
-                <property name="hibernate.hikari.dataSource.url" value="jdbc:mysql://localhost:3306/hello_world?jdbcCompliantTruncation=false&amp;elideSetAutoCommits=true&amp;useLocalSessionState=true&amp;cachePrepStmts=true&amp;cacheCallableStmts=true&amp;alwaysSendSetIsolation=false&amp;prepStmtCacheSize=4096&amp;cacheServerConfiguration=true&amp;prepStmtCacheSqlLimit=2048&amp;zeroDateTimeBehavior=convertToNull&amp;traceProtocol=false&amp;useUnbufferedInput=false&amp;useReadAheadInput=false&amp;maintainTimeStats=false&amp;useServerPrepStmts&amp;cacheRSMetadata=true" />
-                <property name="hibernate.hikari.dataSource.user" value="benchmarkdbuser" />
-                <property name="hibernate.hikari.dataSource.password" value="benchmarkdbpass" />
+                <property name="hibernate.minimumIdle" value="256" />
+                <property name="hibernate.maximumPoolSize" value="256" />
+                <property name="hibernate.idleTimeout" value="30000" />
+                <property name="hibernate.dataSourceClassName" value="org.h2.jdbcx.JdbcDataSource" />
             </properties>
             </properties>
         </persistence-unit>
         </persistence-unit>