fix OpenJPA and PostgreSQL docker setup

This commit is contained in:
Mark Struberg 2021-04-01 16:50:49 +02:00
parent 5b46dcc191
commit 20faa3692c
3 changed files with 14 additions and 25 deletions

View File

@ -201,7 +201,7 @@ For running against a MySQL Docker installation:
-ea -Dopenjpa.ConnectionDriverName=com.mysql.jdbc.Driver -Dopenjpa.ConnectionURL=jdbc:mysql://localhost:3306/openjpatst -Dopenjpa.ConnectionUserName=openjpatst -Dopenjpa.ConnectionPassword=openjpatst
Running against a PostgreSQL Docker installation:
-ea -Dopenjpa.ConnectionDriverName=org.postgresql.Driver -Dopenjpa.ConnectionURL=jdbc:postgresql:5432//localhost/openjpatst -Dopenjpa.ConnectionUserName=postgres -Dopenjpa.ConnectionPassword=postgres
-ea -Dopenjpa.ConnectionDriverName=org.postgresql.Driver -Dopenjpa.ConnectionURL=jdbc:postgresql://localhost:5432/openjpatst -Dopenjpa.ConnectionUserName=postgres -Dopenjpa.ConnectionPassword=postgres
For running against a MariaDB Docker installation:
-ea -Dopenjpa.ConnectionDriverName=org.mariadb.jdbc.Driver -Dopenjpa.ConnectionURL=jdbc:mariadb://localhost:3306/openjpatst -Dopenjpa.ConnectionUserName=root -Dopenjpa.ConnectionPassword=openjpatst
@ -215,7 +215,9 @@ For running against a hsqldb based installation:
For running tests against a Microsoft SQLServer Docker based installation:
-ea -Dopenjpa.ConnectionDriverName=com.microsoft.sqlserver.jdbc.SQLServerDriver -Dopenjpa.ConnectionURL=jdbc:sqlserver://localhost:1433;sendTimeAsDatetime=false -Dopenjpa.ConnectionUserName=SA -Dopenjpa.ConnectionPassword=OpenJP8tst
TODO: finish!
For running against a Oracle Docker installation:
-ea -Dopenjpa.ConnectionDriverName=oracle.jdbc.driver.OracleDriver -Dopenjpa.ConnectionURL=jdbc:oracle:thin:@localhost:1521:xe -Dopenjpa.ConnectionUserName=openjpatst -Dopenjpa.ConnectionPassword=openjpatst
For starting tests in `openjpa-persistence-jdbc` inside a compiler you can also trigger all the enhancement manually via:

28
pom.xml
View File

@ -78,7 +78,7 @@
<hsqldb.version>2.4.1</hsqldb.version>
<mysql.connector.version>5.1.47</mysql.connector.version>
<mariadb.connector.version>2.2.0</mariadb.connector.version>
<postgresql.connector.version>42.2.5</postgresql.connector.version>
<postgresql.connector.version>42.2.9</postgresql.connector.version>
<mssql.connector.version>9.2.1.jre8</mssql.connector.version>
<!-- other common versions -->
@ -1496,12 +1496,9 @@
</property>
</activation>
<properties>
<!-- by default we use the Atlassian 3rd Party repo, which contains the dependency -->
<oracle.maven.repo>https://packages.atlassian.com/maven-3rdparty/</oracle.maven.repo>
<oracle.groupid>com.oracle</oracle.groupid>
<oracle.artifactid>ojdbc6</oracle.artifactid>
<oracle.version>11.2.0.4.0-atlassian-hosted</oracle.version>
<oracle.groupid>com.oracle.ojdbc</oracle.groupid>
<oracle.artifactid>ojdbc8</oracle.artifactid>
<oracle.version>19.3.0.0</oracle.version>
<oracle.server.version>latest</oracle.server.version>
<docker.external.oracle.port>1521</docker.external.oracle.port>
@ -1533,20 +1530,6 @@
</dependency>
</dependencies>
<repositories>
<repository>
<id>oracle.repository</id>
<name>Oracle Repository</name>
<url>${oracle.maven.repo}</url>
<layout>default</layout>
<snapshots>
<enabled>false</enabled>
</snapshots>
<releases>
<enabled>true</enabled>
</releases>
</repository>
</repositories>
<build>
<plugins>
@ -1556,7 +1539,8 @@
<configuration>
<images>
<image>
<name>sath89/oracle-12c:${oracle.server.version}</name>
<!--<name>oracledb19c/oracle.19.3.0-ee:oracle19.3.0-ee</name>-->
<name>oracleinanutshell/oracle-xe-11g</name>
<run>
<volumes>
<bind>

View File

@ -25,4 +25,7 @@
CREATE USER openjpatst IDENTIFIED BY openjpatst;
GRANT CONNECT, RESOURCE, DBA TO openjpatst;
GRANT CREATE SESSION GRANT ANY PRIVILEGE TO openjpatst;
GRANT UNLIMITED TABLESPACE TO openjpatst;
GRANT UNLIMITED TABLESPACE TO openjpatst;
-- to avoid ORA-12519, TNS:no appropriate service handler found
alter system set processes=250 scope=spfile;