Can i delete datasource ExampleDS?

I’m using standalone Keycloak with a SQL-Server DB. My DB is configured via KeycloakDSdatasource in standalone.xml.
Next to it is a preconfigured datasource ExampleDS. The name indidcates, that this is an template, but when i delete it Keycloak doesn’t start anymore:
ERROR [] (Controller Boot Thread) WFLYCTL0013: Operation (“add”) failed - address: ([(“deployment” => “keycloak-server.war”)]) - failure description: {
“WFLYCTL0412: Required services that are not installed:” => [“”],
“WFLYCTL0180: Services with missing/unavailable dependencies” => [“ is missing []”]

This datasource is referenced in subsystem xmlns=“urn:jboss:domain:ee:5.0”.

So, what’s the job of this datasource? How to remove it?

You are not alone, I hit the same so just put it back…glad you asked since having “example” in my production config always bothered me. :slight_smile:

This is an Wildfly default config, not Keycloak, but it can be removed with 2 steps:

1 Like

In my experience, once the new datasource was configured and working removing ExampleDS took three changes to the appropriate standalone[-ha].xml file:

  1. remove the entire “ExampleDS” <datasource> element
  2. remove the entire “h2” <driver> element
  3. substitute “ExampleDS” with the name of your new datasource (e.g. KeycloakDSdatasource ) within the “datasource” attribute of the <default-bindings> element which is below <subsystem xmlns=“urn:jboss:domain:ee:6.0”>