3 Replies Latest reply on Mar 17, 2011 11:39 AM by andrey123

    method not found error

    andrey123 Newbie



      I'm a newbie to JBoss and Java as well and have an issue I can't figure out. I'm getting error below. I've created a simple Java interface using org.jboss.system.ServiceMBean so that I can have this service run in background. The purpose of the service is to run in background and collect data from MQ queue and transfer it over to Oracle DB. The goal of the service is to stay up 24/7 and handle issues like MQ down or Database down or some other issue with either one of those (can't read queue, or can't insert into db etc.). Everything with MQ and while DB is up works fine. But when DB goes down and is not accessible, I get error below. I've been tracking it down for some time and can't figure out what's going on. I think this is happening at JBoss level, but not sure. The is a nested catch in place around DB connection to trap general errors and I've even added SQLException catch into the mix (I know it's not really needed as general catchall Exception would handle this), but I can't seem to find a way to trap error below. I was wondering if any one had this issue before and if there is a way to trap this error so that background service would stay running. My guess here is that when catch kicks in and tries to trap this error it actually can't because the class that has issue does not throw exception???    Any help would be appreciated. Please let me know if you need more details.


      Thank you.


      EDIT: forgot to mention we run JBoss 5.1.0GA on Linux 64bit (red hat)



      14:52:00,831 ERROR [STDERR] Exception in thread "Thread-34"

      14:52:00,831 ERROR [STDERR] java.lang.NoSuchMethodError: javax.resource.ResourceException: method <init>(Ljava/lang/String;Ljava/lang/Throwable;)V not found

      14:52:00,832 ERROR [STDERR] at org.jboss.resource.connectionmanager.BaseConnectionManager2.getManagedConnection(BaseConnectionManager2.java:441)

      14:52:00,832 ERROR [STDERR] at org.jboss.resource.connectionmanager.BaseConnectionManager2.getManagedConnection(BaseConnectionManager2.java:381)

      14:52:00,832 ERROR [STDERR] at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:496)

      14:52:00,832 ERROR [STDERR] at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:941)

      14:52:00,832 ERROR [STDERR] at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:89)

      14:52:00,832 ERROR [STDERR] at com.qd.MQClientUtility.MQJMSConnection.readMessages(MQJMSConnection.java:164)

      14:52:00,832 ERROR [STDERR] at com.qd.MQClientUtility.EMPIMessageConsumer.run(EMPIMessageConsumer.java:77)

      14:52:00,832 ERROR [STDERR] at java.lang.Thread.run(Thread.java:595)