-
Notifications
You must be signed in to change notification settings - Fork 312
Description
Brief Summary
I'm just revisiting #4745.
My use case is this: I have a data source defined in web.xml as this blog post explains. Then I have a Dockerfile where in the build process I warmup Payara Micro:
RUN java -jar payara-micro.jar --rootdir /app --port 8080 --contextroot /context-root --warmup mywar.war
The database server is another container but it is not up when building the app image, so the previous command fails with a java.sql.SQLException: Error in allocating a connection. I think the --skipdsfailure option should be available for Payara Micro too, or some other way to do the warmup without checking the database.
Expected Outcome
Payara Micro warmup should work although a database is not running if a datasource is defined via web.xml.
Current Outcome
Exception: java.sql.SQLException: Error in allocating a connection.
Alternatives
In #4745 it is suggested to define the datasource in a post boot command file, but this requires extra steps and undermines the web.xml facility.
Context
No response