4 Replies Latest reply on Apr 7, 2009 5:41 AM by rasa

    More Than One Ear Deployment

    rasa

      Hi,

      I have an application which is running successfully in jboss 3.2.5. As per the new requirment i need to add one more ear file which has a different work flow. Is it possible to deploy two different ear in a single jboss, then how the ds file will work for different database connection ? Which is the best design that i can do with this requirment ?

      Please guild me

      Thanks and Regards
      Rasa.

        • 1. Re: More Than One Ear Deployment
          jaikiran

           

          Is it possible to deploy two different ear in a single jboss


          Yes you can have any number of EARs deployed in a single instance of JBoss.


          hen how the ds file will work for different database connection ?


          You can deploy separate datasource files (-ds.xml) for each of those applications. The application will then internally have to lookup the appropriate datasource file for itself.


          • 2. Re: More Than One Ear Deployment
            rasa

            hi jai,

            Thanks for your kind attention.


            You can deploy separate datasource files (-ds.xml) for each of those applications. The application will then internally have to lookup the appropriate datasource file for itself.


            Can i give it in a single ds file, if yes how ?

            Thanks and Regards
            Rasa

            • 3. Re: More Than One Ear Deployment
              jaikiran

              Yes, you can have multiple datasources in a single -ds.xml file. See this wiki for an example http://www.jboss.org/community/docs/DOC-9328. See the "Generic Datasource sample" on that page which shows multiple datasources (one local-tx-datasource and one xa-datasource) defined in the same -ds.xml file.

              • 4. Re: More Than One Ear Deployment
                rasa

                ok. Thanks for your help. Can i use local-tx-datasource twice or thrice in a dds file.
                Actually i have given this , but its neither creating a connection or nor giving any exception. If i am wrong, please guide me.

                Thanks and Regards
                Rasa