3 Replies Latest reply on Nov 7, 2012 9:54 AM by jaikiran pai

    standalone.xml datasource enabled-flag are overwritten after second server restart

    nimo stephan Master

      I am using Jboss 7.1.1 FINAL and have 4 datasources defined within standalone.xml.

       

      All works fine.

       

      Now, I want to disable three of them and declare it within standalone.xml by setting enabled="false".

       

      <datasource jta="true" jndi-name="java:/ds-one" pool-name="pool-one" use-java-context="true" use-ccm="true" enabled="true">

      <datasource jta="true" jndi-name="java:/ds-two" pool-name="pool-one" use-java-context="true" use-ccm="true" enabled="false">

      <datasource jta="true" jndi-name="java:/ds-three" pool-name="pool-one" use-java-context="true" use-ccm="true" enabled="false">

      <datasource jta="true" jndi-name="java:jboss/datasources/ExampleDS" pool-name="pool-one" use-java-context="true" use-ccm="true" enabled="false">

       

      When restarting the server again, the three datasources are correctly not bound within the application server, only "java:/ds-one" is bound:

       

      12:49:00,416 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-3) JBAS010400: Bound data source [java:/ds-one]

       

      However, when stopping the server, deploying the web-archive and restarting the server again,

      my settings of the datasources enabled-flag in standalone.xml are changed (but not by myself!).

      The property enabled=false are removed from the standalone.xml.


      Hence, the server bounds the 4 datasources again unfortunately:

       

      12:49:00,416 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-5) JBAS010400: Bound data source [java:/ds-two]

      12:49:00,417 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-6) JBAS010400: Bound data source [java:/ds-three]

      12:49:00,417 INFO  [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-4) JBAS010400: Bound data source [java:jboss/datasources/ExampleDS]

       

       

      Is this a bug?