6 Replies Latest reply on Aug 24, 2004 5:07 AM by lviz

    MULTIPLE WAR FILES PROBLEM

    sk4567

      Hi All,

      I have two applications developed using struts 1.1 deployed on jboss3.2.3. Individually thre are working fine when deployed on separate application servers. But when i deploy both the WAR files on the same server I get strange problems.

      Both the applications having been built on the same framework have same class names..eg: LoginAction class .

      While trying to logon to Application B the LoginAction class of application A is gettign accessed. It is very strange..as I am using different contexts to access the different applications. Can anyone throw some light if i need to tweek any configuration files for this.

      Regards,
      Saurabh Kedia

        • 1. Re: MULTIPLE WAR FILES PROBLEM
          lviz

          hello

          take a look at this thread....
          http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3844915#3844915

          especially
          UseJBossWebLoader:

          cheers
          L

          • 2. Re: MULTIPLE WAR FILES PROBLEM
            sk4567

            hey..

            This option look good..but you know with this turned to false.. I have problems accessing Inner classes within my action classes......


            "I had a similar problem while acessing third party jars placed in the web-inf/lib directory of my application.... Ihad turned the classloader settings to false asn it had worked but gave me problems in accessign inner classes...but somehow after turning it back to true....I was able to access the jars ....."

            Cant we have some kind of application.xml settings....as with some other app servers....

            • 3. Re: MULTIPLE WAR FILES PROBLEM
              sk4567

              I also have problem with my DS Configuration...it picks up the teh first settigns from the mySqldb-ds.xml file..(this is even after changing the classloader settings to false)

              My DS xml file looks like this:


              <local-tx-datasource>
              <!-- remove this depends tag if you are not using the tcp connection url -->
              <jndi-name>fmsDS</jndi-name>
              <!-- for tcp connection, allowing other processes to use the hsqldb database -->
              <connection-url>jdbc:mysql://172.16.40.9/fms</connection-url>
              <!-- for totally in-memory db, not saved when jboss stops. hsql mbean is unnecessary-->
              <!--connection-url>jdbc:hsqldb:.</connection-url-->
              <!-- for in-process db, saved when jboss stops. hsql mbean is unnecessary-->
              <!--connection-url>jdbc:hsqldb:default-db-name</connection-url-->
              <driver-class>com.mysql.jdbc.Driver</driver-class>
              <user-name>root</user-name>

              <!--example of how to specify class that determines if exception means connection should be destroyed-->
              <!--exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyExceptionSorter</exception-sorter-class-name-->
              <min-pool-size>1</min-pool-size>
              <max-pool-size>50</max-pool-size>
              </local-tx-datasource>

              <local-tx-datasource>
              <!-- remove this depends tag if you are not using the tcp connection url -->
              <jndi-name>posDS</jndi-name>
              <!-- for tcp connection, allowing other processes to use the hsqldb database -->
              <connection-url>jdbc:mysql://172.16.40.9/pos</connection-url>
              <!-- for totally in-memory db, not saved when jboss stops. hsql mbean is unnecessary-->
              <!--connection-url>jdbc:hsqldb:.</connection-url-->
              <!-- for in-process db, saved when jboss stops. hsql mbean is unnecessary-->
              <!--connection-url>jdbc:hsqldb:default-db-name</connection-url-->
              <driver-class>com.mysql.jdbc.Driver</driver-class>
              <user-name>pos</user-name>
              pos
              <!--example of how to specify class that determines if exception means connection should be destroyed-->
              <!--exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyExceptionSorter</exception-sorter-class-name-->
              <min-pool-size>1</min-pool-size>
              <max-pool-size>50</max-pool-size>
              </local-tx-datasource>



              I am trying to connect to the 2nd Datasource settings

              • 4. Re: MULTIPLE WAR FILES PROBLEM
                lviz

                hiho

                maybe this is what you looking for:
                http://www.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration

                cheers
                L

                • 5. Re: MULTIPLE WAR FILES PROBLEM
                  sk4567

                  Doesnt really solve my problem......your link simply mentions to tweak the jboss-service.xml file.....Setting this to false doesnt help..still gives datasource errors....and where do i get the
                  jboss-app.xml

                  • 6. Re: MULTIPLE WAR FILES PROBLEM
                    lviz

                    hi Saurabh

                    reading the doc would help ;)
                    http://docs.jboss.org/admin-devel/Chap2.html#0_36191
                    look for jboss-app ;)
                    To enable an EAR specific loader repository, you need to create a META-INF/jboss-app.xml.


                    try to split up your ds config.
                    eg:
                    mySqldbfms-ds.xml, mySqldbpos-ds.xml

                    cheers
                    L