Skip to content

Commit a6dadc5

Browse files
committed
Align Oracle DB setup in quarkus-it-hibernate-reactive-oracle on other ITs
E.g. on quarkus-reactive-oracle-client-deployment, quarkus-it-jpa-oracle. Because the current setup doesn't seem to work.
1 parent dcdd1f8 commit a6dadc5

File tree

2 files changed

+73
-14
lines changed

2 files changed

+73
-14
lines changed

integration-tests/hibernate-reactive-oracle/pom.xml

Lines changed: 72 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<description>Hibernate Reactive related tests running with the Oracle database</description>
1515

1616
<properties>
17-
<reactive-oracle.url>vertx-reactive:oracle:thin:@localhost:1520/hibernate_orm_test</reactive-oracle.url>
17+
<reactive-oracle.url>vertx-reactive:oracle:thin:@localhost:1521/FREEPDB1</reactive-oracle.url>
1818
</properties>
1919

2020
<dependencies>
@@ -186,36 +186,40 @@
186186
<images>
187187
<image>
188188
<name>${oracle.image}</name>
189-
<alias>oracle</alias>
190189
<run>
190+
<ports>
191+
<port>1521:1521</port>
192+
</ports>
191193
<env>
192-
<ORACLE_DATABASE>hibernate_orm_test</ORACLE_DATABASE>
193194
<ORACLE_PASSWORD>hibernate_orm_test</ORACLE_PASSWORD>
194-
<APP_USER>hibernate_orm_test</APP_USER>
195-
<APP_USER_PASSWORD>hibernate_orm_test</APP_USER_PASSWORD>
196195
</env>
197-
<ports>
198-
<port>1520:1521</port>
199-
</ports>
200196
<log>
201-
<prefix>ORACLE:</prefix>
197+
<prefix>Oracle Database: </prefix>
202198
<date>default</date>
203-
<color>cyan</color>
199+
<color>red</color>
204200
</log>
201+
<wait>
202+
<!-- good docs found at: https://dmp.fabric8.io/#build-healthcheck -->
203+
<!-- Unfortunately booting this is slow, needs to set a generous timeout: -->
204+
<time>60000</time>
205+
<!-- leverage the healthcheck in the image we use -->
206+
<healthy>yes</healthy>
207+
<!-- In case of any issues with the built-in healthcheck we can revert back to the original log check:-->
208+
<!--<log>DATABASE IS READY TO USE!</log>-->
209+
</wait>
205210
</run>
206211
</image>
207212
</images>
208-
<!--Stops all Oracle images currently running, not just those we just started.
213+
<!--Stops all Oracle DB images currently running, not just those we just started.
209214
Useful to stop processes still running from a previously failed integration test run -->
210215
<allContainers>true</allContainers>
211216
</configuration>
212217
<executions>
213218
<execution>
214219
<id>docker-start</id>
215-
<phase>pre-integration-test</phase>
220+
<phase>compile</phase>
216221
<goals>
217222
<goal>stop</goal>
218-
<goal>build</goal>
219223
<goal>start</goal>
220224
</goals>
221225
</execution>
@@ -247,6 +251,61 @@
247251
</plugins>
248252
</build>
249253
</profile>
254+
255+
<!-- In general, we want to avoid os- or arch-based guards on tests, but the Oracle
256+
db would not start on M1 - see https://stackoverflow.com/questions/68605011/oracle-12c-docker-setup-on-apple-m1 -->
257+
<profile>
258+
<id>mac-m1</id>
259+
<activation>
260+
<os>
261+
<arch>aarch64</arch>
262+
</os>
263+
</activation>
264+
<build>
265+
<plugins>
266+
<plugin>
267+
<artifactId>maven-surefire-plugin</artifactId>
268+
<configuration>
269+
<skip>true</skip>
270+
</configuration>
271+
</plugin>
272+
<plugin>
273+
<groupId>io.fabric8</groupId>
274+
<artifactId>docker-maven-plugin</artifactId>
275+
<configuration>
276+
<images>
277+
<image>
278+
<name>${oracle.image}</name>
279+
<run>
280+
<skip>true</skip>
281+
</run>
282+
</image>
283+
</images>
284+
</configuration>
285+
</plugin>
286+
</plugins>
287+
</build>
288+
</profile>
289+
<!-- Disabled pending fix of #33094 -->
290+
<profile>
291+
<id>podman</id>
292+
<activation>
293+
<property>
294+
<name>env.IS_PODMAN</name>
295+
<value>true</value>
296+
</property>
297+
</activation>
298+
<build>
299+
<plugins>
300+
<plugin>
301+
<artifactId>maven-surefire-plugin</artifactId>
302+
<configuration>
303+
<skip>true</skip>
304+
</configuration>
305+
</plugin>
306+
</plugins>
307+
</build>
308+
</profile>
250309
</profiles>
251310

252311

integration-tests/hibernate-reactive-oracle/src/main/resources/application.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
quarkus.datasource.db-kind=oracle
2-
quarkus.datasource.username=hibernate_orm_test
2+
quarkus.datasource.username=SYSTEM
33
quarkus.datasource.password=hibernate_orm_test
44

55
# Hibernate config

0 commit comments

Comments
 (0)