9 Replies Latest reply on Apr 27, 2009 8:13 AM by jmesnil

    Configuration layout

    jmesnil

      Our current configuration layout is messy and spread in many places (AS/config, src/config) and is confusing (JMS tests is hard-coded with the bean config from AS/config and the server configuration from src/config)

      We need to clean this up and make it simple.

      the proposal is to reorganize our configs:

      src/config/non-clustered -> beans and configuration for (non-clustered) standalone
      src/config/clustered -> beans and configuration for clustered standalone
      src/config/jbossas/non-clustered/ -> beans for (non-clustered) AS 5 integration
      src/config/jbossas/clustered -> beans for clustered AS 5 integration

      Each of this 4 dirs would contain a full configuration (-beans, jbm-configuration, jbm-jms, jbm-queues, etc.)

      There would be 2 profiles created for JBoss AS 5:
      jbm2_default taking the conf from jbossas/non-clustered
      jbm2_clustered taking the conf from jbossas/clustered

      The jms tests should be refactored to use src/config/non-clustered config (there are tests
      depending on JBoss Security manager which needs to be refactored for that)

      Ideally, integration tests should not depend on a given configuration: it's part of the test setup to configure the server with the configuration suited from the tests.

      This layout change will impact the creation of AS 5 profiles and the Java EE examples (esp. the clustered one).
      If you see a problem with this new layout, speak up now :)


      wdyt?

        • 1. Re: Configuration layout
          jmesnil

           

          "jmesnil" wrote:

          src/config/non-clustered -> beans and configuration for (non-clustered) standalone
          src/config/clustered -> beans and configuration for clustered standalone
          src/config/jbossas/non-clustered/ -> beans for (non-clustered) AS 5 integration
          src/config/jbossas/clustered -> beans for clustered AS 5 integration


          Oups! wrong layout. The correct layout is

          src/config/standalone/non-clustered -> beans and configuration for (non-clustered) standalone
          src/config/standalone/clustered -> beans and configuration for clustered standalone
          src/config/jbossas/non-clustered/ -> beans for (non-clustered) AS 5 integration
          src/config/jbossas/clustered -> beans for clustered AS 5 integration


          • 2. Re: Configuration layout
            timfox

             

            "jmesnil" wrote:

            src/config/non-clustered -> beans and configuration for (non-clustered) standalone
            src/config/clustered -> beans and configuration for clustered standalone
            src/config/jbossas/non-clustered/ -> beans for (non-clustered) AS 5 integration
            src/config/jbossas/clustered -> beans for clustered AS 5 integration


            I would prefer:

            src/config/stand-alone/non-clustered -> beans and configuration for (non-clustered) standalone
            src/config/stand-alone/clustered -> beans and configuration for clustered standalone
            src/config/jbossas/non-clustered/ -> beans for (non-clustered) AS 5 integration
            src/config/jbossas/clustered -> beans for clustered AS 5 integration

            just to be symmetrical


            • 3. Re: Configuration layout
              clebert.suconic

              For jbas, there is some stuff that could go on either clustered or non-clustered.

              Shouldt we have a common dir?

              • 4. Re: Configuration layout
                timfox

                I want to keep the configs completely separate.

                Even if some things are the same now, such as beans files, they might not be in the future, and using a common dir just complicates things and makes them harder to change going ahead.

                • 5. Re: Configuration layout
                  gaohoward

                  Is it possible that we just keep a single set of template configuration files and whoever needs a specific configuration could 'generate' it from the template?

                  We can consider 'velocity' for that purpose. or use ant filtered copy task.

                  • 6. Re: Configuration layout
                    clebert.suconic

                    There is a saying in Brazil that translates my feeling:

                    "The dog bitten by a snake fears sausage".


                    I had personally had hassles while handling auto-generated scripts based on a common template. At the end it took the team I was working at, more time to maintain the messy script than maintaining a few copies.


                    I could be a different experience now (Hence my reference to the brazilian saying)... but I feel a Dejavou when thinking about scripts like that.

                    • 7. Re: Configuration layout
                      gaohoward

                      That's true. :)

                      Chinese has a similar one, in English like:

                      Once got bitten by a snake, one will fear rope for ten years.

                      • 8. Re: Configuration layout
                        timfox

                        I have a saying:

                        "Developer who's task takes too long gets ass kicked by project lead".

                        And one specially for Clebert:

                        "Clebert gets ass kicked anyway"

                        ;)

                        • 9. Re: Configuration layout
                          jmesnil

                          the new config layout has been committed.

                          To create the AS 5 profiles (default-with-jbm2 and all-with-jbm2), run ant from the distribution's config/jboss-as directory.