[keycloak-user] docker image and database - 3 starts?
Rob Shepherd
rgshepherd at gmail.com
Fri Nov 10 06:01:13 EST 2017
Hi,
I’m running kc 3.3.0.FINAL using the docker image.
I’ve setup my database using the POSTGRES_* env vars.
I notice that everytime the server is started, there are actually 3 starts
I’m guessing the issue with WFLYCTL0212 is that the batch CLI change is attempting to set the jdbc driver parameters that already exists.
But why does it attempt it a second time before finally starting properly?
Presumably the way to workaround this is to just overwrite the parameters in standalone.xml directly, avoiding POSTGRES_* style env vars which will then ignore the change-database stuff?
here are the pertinent snippets…
1.
10:53:47,050 INFO [org.jboss.as.server] (Controller Boot Thread) WFLYSRV0212: Resuming server
10:53:47,054 INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0025: Keycloak 3.3.0.Final (WildFly Core 3.0.8.Final) started in 7188ms - Started 67 of 79 services (23 services are lazy, passive or on-demand)
The batch failed with the following error: :
WFLYCTL0062: Composite operation failed and was rolled back. Steps that failed:
Step: step-9
Operation: /subsystem=datasources/jdbc-driver=postgresql:add(driver-name=postgresql, driver-module-name=org.postgresql.jdbc, driver-xa-datasource-class-name=org.postgresql.xa.PGXADataSource)
Failure: WFLYCTL0212: Duplicate resource [
("subsystem" => "datasources"),
("jdbc-driver" => "postgresql")
]
10:53:47,388 INFO [org.jboss.as] (MSC service thread 1-4) WFLYSRV0050: Keycloak 3.3.0.Final (WildFly Core 3.0.8.Final) stopped in 25ms
2.
10:54:00,061 INFO [org.jboss.as.server] (Controller Boot Thread) WFLYSRV0212: Resuming server
10:54:00,067 INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0025: Keycloak 3.3.0.Final (WildFly Core 3.0.8.Final) started in 10751ms - Started 65 of 84 services (30 services are lazy, passive or on-demand)
The batch failed with the following error: :
WFLYCTL0062: Composite operation failed and was rolled back. Steps that failed:
Step: step-9
Operation: /subsystem=datasources/jdbc-driver=postgresql:add(driver-name=postgresql, driver-module-name=org.postgresql.jdbc, driver-xa-datasource-class-name=org.postgresql.xa.PGXADataSource)
Failure: WFLYCTL0212: Duplicate resource [
("subsystem" => "datasources"),
("jdbc-driver" => "postgresql")
]
10:54:00,720 INFO [org.jboss.as] (MSC service thread 1-3) WFLYSRV0050: Keycloak 3.3.0.Final (WildFly Core 3.0.8.Final) stopped in 49ms
3.rd time lucky…
=========================================================================
JBoss Bootstrap Environment
JBOSS_HOME: /opt/jboss/keycloak
JAVA: /usr/lib/jvm/java/bin/java
JAVA_OPTS: -server -Djava.security.egd=file:/dev/./urandom -Djava.net.preferIPv4Stack=true -XX:MaxPermSize=256m
=========================================================================
OpenJDK 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
10:54:03,396 INFO [org.jboss.modules] (main) JBoss Modules version 1.6.1.Final
10:54:04,483 INFO [org.jboss.msc] (main) JBoss MSC version 1.2.7.SP1
10:54:04,989 INFO [org.jboss.as] (MSC service thread 1-1) WFLYSRV0049: Keycloak 3.3.0.Final (WildFly Core 3.0.8.Final) starting
More information about the keycloak-user
mailing list