简体   繁体   English

如何使用JMeter测试WSO2 Message Broker

[英]How to test WSO2 Message Broker with JMeter

I'm having some issues getting JMeter to work against the WSO2 Message Broker using the JMS Publisher. 我在使JMeter使用JMS Publisher对抗WSO2消息代理方面遇到一些问题。 I had JMeter working against ActiveMQ but I'm still new with the tool. 我让JMeter与ActiveMQ进行了合作,但是我对该工具还是陌生的。

I copied the client libraries over to jmeter wso2mb-2.0.1\\client-lib to apache-jmeter-2.9\\lib 我将客户端库复制到jmeter wso2mb-2.0.1 \\ client-lib到apache-jmeter-2.9 \\ lib

  • andes-client-0.13.wso2v4.jar andes-client-0.13.wso2v4.jar
  • geronimo-jms_1.1_spec-1.1.0.wso2v1.jar geronimo-jms_1.1_spec-1.1.0.wso2v1.jar

Settings: 设定:

  • Context Factory : org.wso2.andes.jndi.PropertiesFileInitialContextFactory 上下文工厂:org.wso2.andes.jndi.PropertiesFileInitialContextFactory
  • Provider Url : amqp://admin:admin@clientID/carbon?brokerlist='tcp://localhost:5672' 提供商网址:amqp:// admin:admin @ clientID / carbon?brokerlist ='tcp:// localhost:5672'
  • Connection Factory : qpidConnectionfactory 连接工厂:qpidConnectionfactory

...also tried several other values ...还尝试了其他几个值

  • Destination: dynamicQueues/test 目标:dynamicQueues / test

The error I'm getting is on the Connection Factory field. 我收到的错误是在“连接工厂”字段上。
I've tried several different values all of which generate a naming error like there is a setting missing. 我尝试了几种不同的值,所有这些值都会产生命名错误,例如缺少设置。
When I leave it blank I get: 当我将其留空时,我得到:

javax.naming.NamingException: Expected javax.jms.ConnectionFactory, found org.wso2.andes.jndi.ReadOnlyContext javax.naming.NamingException:预期的javax.jms.ConnectionFactory,找到org.wso2.andes.jndi.ReadOnlyContext

Does anyone know what I'm missing here? 有人知道我在这里想念的吗?
Suspect it's something simple. 怀疑这很简单。

I found the problem. 我发现了问题。

In short the qpid context factory org.wso2.andes.jndi.PropertiesFileInitialContextFactory does not use fields the same way as the activeMQ context factory org.apache.activemq.jndi.ActiveMQInitialContextFactory . 简而言之,qpid上下文工厂org.wso2.andes.jndi.PropertiesFileInitialContextFactory使用的字段与activeMQ上下文工厂org.apache.activemq.jndi.ActiveMQInitialContextFactory

While ActiveMQ allows you to not use a separate properties file with Jmeter, Qpid does not. 尽管ActiveMQ允许您不对Jmeter使用单独的属性文件,但Qpid不能。

Jmeter JMS Publisher: Jmeter JMS发布者:

  • Context Factory : org.wso2.andes.jndi.PropertiesFileInitialContextFactory 上下文工厂:org.wso2.andes.jndi.PropertiesFileInitialContextFactory
  • Provider Url : nameOfYouFile.properties 提供者网址:nameOfYouFile.properties
  • Connection Factory : qpidConnectionfactory 连接工厂:qpidConnectionfactory
  • Destination : <QueuePropertyName> 目标: <QueuePropertyName>

nameOfYouFile.properties: nameOfYouFile.properties:

connectionfactory.qpidConnectionfactory = amqp://admin:admin@clientID/carbon?brokerlist='tcp://localhost:5672'
queue.JMeterQueue = JMeterQueue

Reference: Qpid Wiki 参考: Qpid Wiki

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM