6 Replies Latest reply on Apr 23, 2008 6:21 AM by Kevin Conner

    Multiple ESB communication across multiple JVMs

    David Sun Newbie

      We have multiple ESBs running in their own JVM on seevral physical boxes. To enable communication among services, according to previous post, the only requirement would be that they share the registry configuration, i.e. that the local jUDDI instances use the same database.


      Here is my case
      On box1
      C:\jboss\server\tibcoA\

      on Box2
      C:\jboss\server\tibcoB\

      Both boxes have access to a shared drive D: which holds jUUDI database folder D:\data\hypersonic and D:\data\tx-object-store

      In both box, I edited run.bat to add the following line
      set JAVA_OPTS=%JAVA_OPTS% -Djboss.server.data.dir=D:/data

      When I start run.bat on box1, it's ok. But if I start run.bat on box2, I saw a lot of erxceptions.

      What's wrong with my configuration? Will there be a conflict when 2 ESBs try to write to the same jUDDI database simultenously? Anyone have successfully tested such a scenario?

      Thanks

        • 1. Re: Multiple ESB communication across multiple JVMs
          Mark Little Master

          You want to tell us what Exceptions you see?

          • 2. Re: Multiple ESB communication across multiple JVMs
            David Sun Newbie

            Here is my error log when I start esb in 2nd JVM

            2008-04-18 12:18:33,866 ERROR [main] org.jboss.deployment.scanner.URLDeploymentScanner - Incomplete Deployment listing:

            --- Packages waiting for a deployer ---
            org.jboss.deployment.DeploymentInfo@addab412 { url=file:/C:/jboss/server/tibcoCron/deploy/jbossesb.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/jbossesb.esb/
            altDD: null
            lastDeployed: 1208535513835
            lastModified: 1208530489693
            mbeans:

            org.jboss.deployment.DeploymentInfo@84e2ee9a { url=file:/C:/jboss/server/tibcoCron/deploy/jbpm.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/jbpm.esb/
            altDD: null
            lastDeployed: 1208535513835
            lastModified: 1208530405412
            mbeans:

            org.jboss.deployment.DeploymentInfo@7f92dda { url=file:/C:/jboss/server/tibcoCron/deploy/jbrules.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/jbrules.esb/
            altDD: null
            lastDeployed: 1208535513851
            lastModified: 1208530388005
            mbeans:

            org.jboss.deployment.DeploymentInfo@6911bed9 { url=file:/C:/jboss/server/tibcoCron/deploy/management.esb }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/management.esb
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208535513851
            mbeans:

            org.jboss.deployment.DeploymentInfo@c9af3c8d { url=file:/C:/jboss/server/tibcoCron/deploy/smooks.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/smooks.esb/
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208530339583
            mbeans:

            org.jboss.deployment.DeploymentInfo@ed5b2e04 { url=file:/C:/jboss/server/tibcoCron/deploy/soap.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/soap.esb/
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208530337208
            mbeans:

            org.jboss.deployment.DeploymentInfo@7e4a5a02 { url=file:/C:/jboss/server/tibcoCron/deploy/spring.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/spring.esb/
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208530322770
            mbeans:

            --- Incompletely deployed packages ---
            org.jboss.deployment.DeploymentInfo@addab412 { url=file:/C:/jboss/server/tibcoCron/deploy/jbossesb.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/jbossesb.esb/
            altDD: null
            lastDeployed: 1208535513835
            lastModified: 1208530489693
            mbeans:

            org.jboss.deployment.DeploymentInfo@84e2ee9a { url=file:/C:/jboss/server/tibcoCron/deploy/jbpm.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/jbpm.esb/
            altDD: null
            lastDeployed: 1208535513835
            lastModified: 1208530405412
            mbeans:

            org.jboss.deployment.DeploymentInfo@7f92dda { url=file:/C:/jboss/server/tibcoCron/deploy/jbrules.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/jbrules.esb/
            altDD: null
            lastDeployed: 1208535513851
            lastModified: 1208530388005
            mbeans:

            org.jboss.deployment.DeploymentInfo@6911bed9 { url=file:/C:/jboss/server/tibcoCron/deploy/management.esb }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/management.esb
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208535513851
            mbeans:

            org.jboss.deployment.DeploymentInfo@c9af3c8d { url=file:/C:/jboss/server/tibcoCron/deploy/smooks.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/smooks.esb/
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208530339583
            mbeans:

            org.jboss.deployment.DeploymentInfo@ed5b2e04 { url=file:/C:/jboss/server/tibcoCron/deploy/soap.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/soap.esb/
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208530337208
            mbeans:

            org.jboss.deployment.DeploymentInfo@7e4a5a02 { url=file:/C:/jboss/server/tibcoCron/deploy/spring.esb/ }
            deployer: null
            status: null
            state: INIT_WAITING_DEPLOYER
            watch: file:/C:/jboss/server/tibcoCron/deploy/spring.esb/
            altDD: null
            lastDeployed: 1208535513866
            lastModified: 1208530322770
            mbeans:

            --- MBeans waiting for other MBeans ---
            ObjectName: jboss.esb:service=JuddiRMI
            State: CONFIGURED
            I Depend On:
            jboss.jca:service=DataSourceBinding,name=juddiDB
            jboss.esb:service=PropertyService
            Depends On Me:
            jboss.esb:service=ESBDeployer

            ObjectName: jboss.esb:service=ESBDeployer
            State: CONFIGURED
            I Depend On:
            jboss.esb:service=ESBRegistry
            jboss.esb:service=JuddiRMI

            ObjectName: jboss.jca:service=LocalTxCM,name=juddiDB
            State: CONFIGURED
            I Depend On:
            jboss.jca:service=ManagedConnectionPool,name=juddiDB
            jboss.jca:service=CachedConnectionManager
            jboss:service=TransactionManager
            Depends On Me:
            jboss.jca:service=DataSourceBinding,name=juddiDB

            ObjectName: jboss.jca:service=ManagedConnectionPool,name=juddiDB
            State: CONFIGURED
            I Depend On:
            jboss.jca:service=ManagedConnectionFactory,name=juddiDB
            Depends On Me:
            jboss.jca:service=LocalTxCM,name=juddiDB

            ObjectName: jboss.jca:service=ManagedConnectionFactory,name=juddiDB
            State: CONFIGURED
            I Depend On:
            jboss:service=Hypersonic,database=juddiDB
            jboss.jca:service=RARDeployment,name='jboss-local-jdbc.rar'
            Depends On Me:
            jboss.jca:service=ManagedConnectionPool,name=juddiDB

            ObjectName: jboss.jca:service=DataSourceBinding,name=juddiDB
            State: CONFIGURED
            I Depend On:
            jboss.jca:service=LocalTxCM,name=juddiDB
            Depends On Me:
            jboss.esb:service=JuddiRMI

            ObjectName: jboss:service=Hypersonic,database=juddiDB
            State: FAILED
            Reason: java.sql.SQLException: The database is already in use by another process: org.hsqldb.persist.NIOLockFile@64acf5c2[file =C:\data\hypersonic\juddiDB.lck, exists=true, locked=false, valid=false, fl =null]: java.lang.Exception: The process cannot access the file because another process has locked a portion of the file : C:\data\hypersonic\juddiDB.lck
            Depends On Me:
            jboss.jca:service=ManagedConnectionFactory,name=juddiDB

            ObjectName: jboss:service=Hypersonic,database=localDB
            State: FAILED
            Reason: java.sql.SQLException: The database is already in use by another process: org.hsqldb.persist.NIOLockFile@a78b4ed1[file =C:\data\hypersonic\localDB.lck, exists=true, locked=false, valid=false, fl =null]: java.lang.Exception: The process cannot access the file because another process has locked a portion of the file : C:\data\hypersonic\localDB.lck
            Depends On Me:
            jboss.jca:service=ManagedConnectionFactory,name=DefaultDS

            ObjectName: jboss:service=Hypersonic,database=ManagementDS
            State: FAILED
            Reason: java.sql.SQLException: The database is already in use by another process: org.hsqldb.persist.NIOLockFile@de5e1d76[file =C:\data\hypersonic\ManagementDS.lck, exists=true, locked=false, valid=false, fl =null]: java.lang.Exception: The process cannot access the file because another process has locked a portion of the file : C:\data\hypersonic\ManagementDS.lck
            Depends On Me:
            jboss.jca:service=ManagedConnectionFactory,name=ManagementDS

            --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
            ObjectName: jboss:service=Hypersonic,database=localDB
            State: FAILED
            Reason: java.sql.SQLException: The database is already in use by another process: org.hsqldb.persist.NIOLockFile@a78b4ed1[file =C:\data\hypersonic\localDB.lck, exists=true, locked=false, valid=false, fl =null]: java.lang.Exception: The process cannot access the file because another process has locked a portion of the file : C:\data\hypersonic\localDB.lck
            Depends On Me:
            jboss.jca:service=ManagedConnectionFactory,name=DefaultDS

            ObjectName: jboss:service=Hypersonic,database=ManagementDS
            State: FAILED
            Reason: java.sql.SQLException: The database is already in use by another process: org.hsqldb.persist.NIOLockFile@de5e1d76[file =C:\data\hypersonic\ManagementDS.lck, exists=true, locked=false, valid=false, fl =null]: java.lang.Exception: The process cannot access the file because another process has locked a portion of the file : C:\data\hypersonic\ManagementDS.lck
            Depends On Me:
            jboss.jca:service=ManagedConnectionFactory,name=ManagementDS

            ObjectName: jboss:service=Hypersonic,database=juddiDB
            State: FAILED
            Reason: java.sql.SQLException: The database is already in use by another process: org.hsqldb.persist.NIOLockFile@64acf5c2[file =C:\data\hypersonic\juddiDB.lck, exists=true, locked=false, valid=false, fl =null]: java.lang.Exception: The process cannot access the file because another process has locked a portion of the file : C:\data\hypersonic\juddiDB.lck
            Depends On Me:
            jboss.jca:service=ManagedConnectionFactory,name=juddiDB


            • 3. Re: Multiple ESB communication across multiple JVMs
              Kevin Conner Master

              HSQL does not support clustering in this way, you need to use another DB

              • 4. Re: Multiple ESB communication across multiple JVMs
                Noel Rocher Apprentice

                Moreover, hsqldb should only be use for demo only.
                What you see is that only one process can hold the *DB lock*.

                • 5. Re: Multiple ESB communication across multiple JVMs
                  David Sun Newbie

                  ESB uses hsql for multiple purposes and jUDDI is just one of them.
                  WHich files should I change to switch from HSQL to Oracle so that I can use Oracle as jUDDI database? Do I have to use a Oracle cluster?

                  • 6. Re: Multiple ESB communication across multiple JVMs
                    Kevin Conner Master

                    jUDDI is configured to use its own datasource, configured through juddi-ds.xml and esb.juddi.xml.

                    You need to change the juddi-ds.xml to define an Oracle datasource and then the juddi.sqlFiles entry in esb.juddi.xml to use the oracle scripts.