使用ActiveMQ PooledConnectionFactory时出错

时间:2014-04-10 04:24:39

标签: java jms activemq apache-commons-pool

我正在使用ActiveMQ PooledConnectionFactory

PooledConnectionFactory connectionFactory = new PooledConnectionFactory(Constants.AAMQ_MESSAGE_BROKER_URI);
Connection tempConnection = connectionFactory.createConnection(queueUName, queuePwd);

生成以下异常

  

引起:java.lang.NoSuchMethodError:   org.apache.commons.pool.impl.GenericKeyedObjectPool.setLifo(Z)V at   org.apache.activemq.pool.PooledConnectionFactory.createConnection(PooledConnectionFactory.java:213)     在   com.model.util.MyJMSClient.createNewConnection(MyJMSClient.java:393)     在com.model.util.MyJMSClient.getConnection(MyJMSClient.java:386)at   com.model.util.MyJMSClient.executeCommandASync(MyJMSClient.java:179)     在com.model.util.MyJMSClient.executeCommand(MyJMSClient.java:104)     在   com.model.util.WinCommandRunner.executeCommand(WinCommandRunner.java:99)

我在classspath中有公共池和其他库

0 个答案:

没有答案