Why ERROR "DefaultDataSource is missing [jboss.naming.context.java.jboss.datasources.ExampleDS" happens after removing default ExampleDS datasource in JBoss EAP 7?

Solution Verified - Updated -

Issue

  • If the default datasource ExampleDS is removed from JBoss EAP, applications are not getting deployed successfully, even though those applications do not need that ExampleDS datasource. Errors like the following will be logged.
ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("add") failed - address: ([("deployment" => "myapp.war")]) - failure description: {"WFLYCTL0180: Services with missing/unavailable dependencies" => ["jboss.naming.context.java.module.myapp.myapp.DefaultDataSource is missing [jboss.naming.context.java.jboss.datasources.ExampleDS]"]}
  • In previous versions of JBoss EAP removing ExampleDS datasource was not giving this issue.

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 7.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In