4 Replies Latest reply on Jun 5, 2012 7:52 AM by steel_brs

    Configure standalone subsystems from external file

    nnanda

      Hi,

       

      I am using JBoss 7 AS 7.1 beta and using standalone configuration.

       

      My question is, does JBoss allow to configure a single subsystem through an external file? For an example, let's say I create a logging configuration files "logging-config.xml" and define the logging subsytem in that file. How can I include that in standalone.xml?

       

      Thanks in advance.

       

      Niranjan

        • 1. Re: Configure standalone subsystems from external file
          jaikiran

          No that's not supported.

          • 2. Re: Configure standalone subsystems from external file
            nnanda

            Hi Jaikiran,

             

            Thanks for the quick reply. I understand JBoss 7 has made all their configurations in one place which is nice (at least now as infrastructure admin, I do not have to remember all those separate files ).

             

            But in our application, many times we need to repoint databases or change log levels. And with so many instances running its really tuff to change manually. With JBoss 5.1 since those configs are separate files, we used to write scripts to change the file alone and no manual work was involved. Here it seems we have to do manual work. Not that bad, but yea to some extent complicated!!

             

            Best,

            Niranjan

            • 3. Re: Configure standalone subsystems from external file
              jaikiran

              NIranjan Nanda wrote:

               

               

              But in our application, many times we need to repoint databases or change log levels. And with so many instances running its really tuff to change manually.

              That's exactly why we introduced the domain management in AS7 - to avoid any manual changes to multiple systems. Take a look at the AS7 documentation https://docs.jboss.org/author/display/AS71/Documentation and read about the management APIs and the command line interface which you can use write scripts or even use the admin console to manage the domain.

               

               

              NIranjan Nanda wrote:

               

              With JBoss 5.1 since those configs are separate files, we used to write scripts to change the file alone and no manual work was involved. Here it seems we have to do manual work. Not that bad, but yea to some extent complicated!!

               

              In AS7, we no longer recommend manually changing anything in the configuration file (standalone.xml/domain.xml). Instead we provide management operations and tools which can invoke those management operations to let you change any/all the settings and those settings will be persisted back to the configuration file. Take a look at the various chapters in the documentation I pointed you to.

              • 4. Re: Configure standalone subsystems from external file
                steel_brs

                NIranjan Nanda wrote:

                 

                But in our application, many times we need to repoint databases or change log levels. And with so many instances running its really tuff to change manually. With JBoss 5.1 since those configs are separate files, we used to write scripts to change the file alone and no manual work was involved. Here it seems we have to do manual work. Not that bad, but yea to some extent complicated!!

                For log level changing at runtime see http://stackoverflow.com/questions/10896282/just-so-you-know-per-deployed-webapp-slf4j-logback-in-jboss-7-1-1