2 Replies Latest reply on Jun 23, 2003 8:48 AM by saqibsaleem

    Jboss 3.2.1 and MySQL 4

    saqibsaleem

      HI.

      I am attempting to use mysql with jboss 3.2.1.
      I have copied the mysql-ds.xml file from examples to the default/deploy. I have updated standard default/conf/standardjbosscmp-jdbc.xml to look at the new ds definition. When I start JBoss is throws the following exception(below). However, once it has finished starting, it then continues to work seemingly OK. Can anyone tell me why this exception gets thrown and where is the user 'SA' being set? Is it still attempting to communicate with hypersonic? Can I get it to talk to mysql for this instead?

      Thanks in advance.

      2003-06-09 21:30:01,542 DEBUG [org.jboss.system.ServiceController] starting service jboss.mq:service=PersistenceManager
      2003-06-09 21:30:01,542 INFO [org.jboss.mq.pm.jdbc2.PersistenceManager] Starting
      2003-06-09 21:30:01,542 DEBUG [org.jboss.mq.pm.jdbc2.PersistenceManager] Resolving uncommited TXS
      2003-06-09 21:30:01,622 DEBUG [org.jboss.resource.connectionmanager.IdleRemover] internalRegisterPool: registering pool with interval 900000 old interval: 9223372036854775807
      2003-06-09 21:30:01,622 DEBUG [org.jboss.resource.connectionmanager.IdleRemover] internalRegisterPool: about to notify thread: old next: 1055191051622, new next: 1055191051622
      2003-06-09 21:30:01,622 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Using properties: {user=sa, password=}
      2003-06-09 21:30:01,622 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Checking driver for URL: jdbc:hsqldb:hsql://localhost:1701
      2003-06-09 21:30:01,622 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Driver not yet registered for url: jdbc:hsqldb:hsql://localhost:1701
      2003-06-09 21:30:01,632 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Driver not yet registered for url: jdbc:hsqldb:hsql://localhost:1701
      2003-06-09 21:30:01,632 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Driver already registered for url: jdbc:hsqldb:hsql://localhost:1701
      2003-06-09 21:30:01,662 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Using properties: {user=sa, password=}
      2003-06-09 21:30:01,662 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Using properties: {user=sa, password=}
      2003-06-09 21:30:01,662 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Using properties: {user=sa, password=}
      2003-06-09 21:30:01,662 DEBUG [org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory] Using properties: {user=sa, password=}
      2003-06-09 21:30:01,722 DEBUG [org.jboss.util.NestedThrowable] org.jboss.util.NestedThrowable.parentTraceEnabled=true
      2003-06-09 21:30:01,732 DEBUG [org.jboss.util.NestedThrowable] org.jboss.util.NestedThrowable.nestedTraceEnabled=false
      2003-06-09 21:30:01,732 DEBUG [org.jboss.util.NestedThrowable] org.jboss.util.NestedThrowable.detectDuplicateNesting=true
      2003-06-09 21:30:01,722 WARN [org.jboss.tm.TransactionImpl] XAException: tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=workstation//1, BranchQual=] errorCode=XA_UNKNOWN(0)
      org.jboss.resource.connectionmanager.JBossLocalXAException: Error trying to start local tx: ; - nested throwable: (org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: User not found: SA))
      at org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.start(TxConnectionManager.java:729)
      at org.jboss.tm.TransactionImpl.startResource(TransactionImpl.java:1137)
      at org.jboss.tm.TransactionImpl.enlistResource(TransactionImpl.java:624)
      at org.jboss.resource.connectionmanager.TxConnectionManager$TxConnectionEventListener.enlist(TxConnectionManager.java:460)
      at org.jboss.resource.connectionmanager.TxConnectionManager.managedConnectionReconnected(TxConnectionManager.java:358)
      at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:490)
      at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:798)
      at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:102)
      at org.jboss.mq.pm.jdbc2.PersistenceManager.getConnection(PersistenceManager.java:1206)
      at org.jboss.mq.pm.jdbc2.PersistenceManager.resolveAllUncommitedTXs(PersistenceManager.java:219)
      at org.jboss.mq.pm.jdbc2.PersistenceManager.startService(PersistenceManager.java:1299)
      at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:192)
      at sun.reflect.GeneratedMethodAccessor33.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:966)
      at $Proxy11.start(Unknown Source)
      at org.jboss.system.ServiceController.start(ServiceController.java:392)
      at org.jboss.system.ServiceController.start(ServiceController.java:408)
      at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
      at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
      at $Proxy5.start(Unknown Source)
      at org.jboss.deployment.SARDeployer.start(SARDeployer.java:226)
      at org.jboss.deployment.MainDeployer.start(MainDeployer.java:832)
      at org.jboss.deployment.MainDeployer.start(MainDeployer.java:824)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:640)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:613)
      at sun.reflect.GeneratedMethodAccessor26.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
      at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
      at $Proxy7.deploy(Unknown Source)
      at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:302)
      at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:476)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:200)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:273)
      at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:192)
      at sun.reflect.GeneratedMethodAccessor7.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:966)
      at $Proxy0.start(Unknown Source)
      at org.jboss.system.ServiceController.start(ServiceController.java:392)
      at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
      at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
      at $Proxy5.start(Unknown Source)
      at org.jboss.deployment.SARDeployer.start(SARDeployer.java:226)
      at org.jboss.deployment.MainDeployer.start(MainDeployer.java:832)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:640)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:613)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:597)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)
      at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
      at $Proxy6.deploy(Unknown Source)
      at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:365)
      at org.jboss.system.server.ServerImpl.start(ServerImpl.java:272)
      at org.jboss.Main.boot(Main.java:150)
      at org.jboss.Main$1.run(Main.java:388)
      at java.lang.Thread.run(Thread.java:536)
      Caused by: org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: User not found: SA)
      at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.checkException(BaseWrapperManagedConnection.java:445)
      at org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.begin(LocalManagedConnection.java:153)
      at org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.start(TxConnectionManager.java:725)
      ... 77 more
      Caused by: java.sql.SQLException: User not found: SA
      at org.hsqldb.Trace.getError(Unknown Source)
      at org.hsqldb.Result.(Unknown Source)
      at org.hsqldb.jdbcConnection.executeHSQL(Unknown Source)
      at org.hsqldb.jdbcConnection.execute(Unknown Source)
      at org.hsqldb.jdbcConnection.setAutoCommit(Unknown Source)
      at org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.begin(LocalManagedConnection.java:147)
      ... 78 more

        • 1. Re: Jboss 3.2.1 and MySQL 4
          billgong

          A checklist of the files that u may need to add, delete and/or modify:

          a. hsqldb-service.xml
          b. mysql-ds.xml
          c. MySql J/Connector (I use mysql-connector-java-3.0.8-stable-bin.jar)
          d. login-config.xml
          e. standardjbosscmp-jdbc.xml
          f. standardjaws.xml
          g. jbossmq-service.xml

          Have u done with all these files?
          ps, u may get another exception if u'r using MySql4.0.x, cauz it doesn't support sub-queries. Try to download and use 4.1.0-Alpha, it works.

          --bill

          • 2. Re: Jboss 3.2.1 and MySQL 4
            saqibsaleem

            Thanks billbong - that worked a treat!