3 Replies Latest reply on Jun 28, 2012 8:09 PM by andersonvass

    Is possible to break the standalone.xml in multiple files?

    andersonvass

      Hi

       

      It's possible to break the configurations of standalone.xml in multiple files and deploy this files with the .ear?

       

      I wan't to separate the queue and naming configurations in others files. In old Jboss, i just put in some xml file in the deploy folder that jboss automatically deploy this configuration. Is this possible in jboss 7? Or is possible to attach standalone.xml in .ear package?

       

       

      Thanks

        • 1. Re: Is possible to break the standalone.xml in multiple files?
          bwallis42

          standalone.xml is the server configuration file, required to start the server and the server can and does rewrite the file. There is only one and it cannot be deployed as part of something else.

           

          That said, from the release notes for 7.1 (https://community.jboss.org/wiki/AS710FinalReleaseNotes)

           

          {quote}

          • Deployable datasources and JMS destinations are back

          {quote}

           

          Is this what you want? I've used deployable datasources, ie: deploy a file called mydb-ds.xml to create the database connection pool with a particular JNDI name. See this article, https://community.jboss.org/en/tools/blog/2012/02/28/excited-about-jboss-as-71-part-i-deployable-datasources

           

          I didn't find a blog article for the JMS destinations but something like this (from the test cases) should work (I haven't used this yet).

           

           

          {code:xml}

          <?xml version="1.0" encoding="UTF-8"?>

          <messaging-deployment xmlns="urn:jboss:messaging-deployment:1.0">

              <hornetq-server>

                  <jms-destinations>

                      <jms-queue name="queue1">

                          <entry name="java:/queue1"/>

                          <durable>true</durable>

                      </jms-queue>

                      <jms-topic name="topic1">

                          <entry name="java:/topic1"/>

                      </jms-topic>

                  </jms-destinations>

              </hornetq-server>

          </messaging-deployment>

          {code}

          1 of 1 people found this helpful
          • 2. Re: Is possible to break the standalone.xml in multiple files?
            wdfink

            The central configuration is one of the key features of AS7.

            The deployable datasource files are not reccomended for production use!

             

            If you want to have such extra file the recommended way is to use a script for the CLI command, with this you can simple add or remove any configuration to an existing instance without notice other (different) configurations.

            BTW, the CLI or admin console are the recommended way to configure JBoss AS7.

            1 of 1 people found this helpful
            • 3. Re: Is possible to break the standalone.xml in multiple files?
              andersonvass

              Thanks for the replies. I would avaliate the both answers to decide what to do.