使用JMeter对JMS消息队列进行功能测试

时间:2021-07-07 03:52:27

I've got a REST service that in response to a request, posts a message on a JMS queue. All of the main http functional testing is done using JMeter, so I was wondering if anyone has successfully pulled a JMS message off an existing queue in JMeter?

我有一个REST服务,响应请求,在JMS队列上发布消息。所有主要的http功能测试都是使用JMeter完成的,所以我想知道是否有人成功地从JMeter中的现有队列中提取了JMS消息?

1 个解决方案

#1


JMeter will do no such thing, but a class that you write to extend MessageListener, register with the queue, and have JMeter instantiate in a JUnit test certainly can. I'd recommend that you keep the consuming and testing separate. Write that MessageListener, get it working, and then figure out how to wire it into JMeter.

JMeter不会做这样的事情,但是你编写的类来扩展MessageListener,向队列注册,并且在JUnit测试中实例化JMeter当然可以。我建议您将消耗和测试分开。写下MessageListener,让它工作,然后弄清楚如何将它连接到JMeter。

#1


JMeter will do no such thing, but a class that you write to extend MessageListener, register with the queue, and have JMeter instantiate in a JUnit test certainly can. I'd recommend that you keep the consuming and testing separate. Write that MessageListener, get it working, and then figure out how to wire it into JMeter.

JMeter不会做这样的事情,但是你编写的类来扩展MessageListener,向队列注册,并且在JUnit测试中实例化JMeter当然可以。我建议您将消耗和测试分开。写下MessageListener,让它工作,然后弄清楚如何将它连接到JMeter。