<?xml version="1.0" encoding="UTF-8"?>
<jmeterTestPlan version="1.2" properties="3.4" jmeter="4.0-SNAPSHOT.20171128">
  <hashTree>
    <TestPlan guiclass="TestPlanGui" testclass="TestPlan" testname="Test Plan" enabled="true">
      <stringProp name="TestPlan.comments"></stringProp>
      <boolProp name="TestPlan.functional_mode">false</boolProp>
      <boolProp name="TestPlan.serialize_threadgroups">true</boolProp>
      <elementProp name="TestPlan.user_defined_variables" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
        <collectionProp name="Arguments.arguments"/>
      </elementProp>
      <stringProp name="TestPlan.user_define_classpath"></stringProp>
      <boolProp name="TestPlan.tearDown_on_shutdown">true</boolProp>
    </TestPlan>
    <hashTree>
      <SetupThreadGroup guiclass="SetupThreadGroupGui" testclass="SetupThreadGroup" testname="setUp Thread Group" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">stoptest</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </SetupThreadGroup>
      <hashTree>
        <JSR223Sampler guiclass="TestBeanGUI" testclass="JSR223Sampler" testname="BSS_startActiveMQ" enabled="true">
          <stringProp name="scriptLanguage">groovy</stringProp>
          <stringProp name="parameters"></stringProp>
          <stringProp name="filename"></stringProp>
          <stringProp name="cacheKey">true</stringProp>
          <stringProp name="script">import org.apache.activemq.broker.BrokerService;
import org.apache.activemq.broker.BrokerFactory;
import org.apache.jmeter.util.JMeterUtils;
import org.apache.commons.io.FileUtils;
import java.io.File;

File file = new File(JMeterUtils.getJMeterHome(), &quot;bin/activemq-data&quot;);
log.info(&quot;Deleting {}&quot;, file);
FileUtils.deleteDirectory(file);
log.info(&quot;Creating activemq config from {}&quot;, JMeterUtils.getJMeterHome()+ &quot;/bin/testfiles/activemq.xml&quot;);
try {
	String path = JMeterUtils.getJMeterHome()+ &quot;/bin/testfiles/activemq.xml&quot;;
	path = path.replace(&apos;\\&apos;, &apos;/&apos;);
	path = path.replaceAll(&quot; &quot;, &quot;%20&quot;);
	BrokerService broker = BrokerFactory.createBroker(&quot;xbean:file:&quot;+path, true);
	props.put(&quot;ACTIVEMQ_BROKER&quot;, broker);
} catch(Exception ex) {
	log.error(&quot;Error configuring ActiveMQ&quot;, ex);
}
</stringProp>
        </JSR223Sampler>
        <hashTree/>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
      </hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="TG-JMS-P2P" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </ThreadGroup>
      <hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-DefaultCorrelationId" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue0</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue">dynamicQueues/requestQueue0</stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">true</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties"/>
          </elementProp>
          <boolProp name="JMSSampler.useResMsgIdAsCorrelId">true</boolProp>
          <intProp name="JMSSampler.communicationStyle">1</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="2603186">Test</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JSR223Sampler guiclass="TestBeanGUI" testclass="JSR223Sampler" testname="JSS-ConsumeUpcomingMessage" enabled="true">
          <stringProp name="cacheKey">true</stringProp>
          <stringProp name="filename"></stringProp>
          <stringProp name="parameters">dynamicQueues/requestQueue0-tmp</stringProp>
          <stringProp name="script">import org.apache.activemq.ActiveMQConnectionFactory;
import javax.jms.*;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import javax.naming.InitialContext;
import javax.naming.Context;
import java.util.Properties;
def thread = Thread.start { 
	Properties props = new Properties();
	props.setProperty(Context.INITIAL_CONTEXT_FACTORY,		&quot;org.apache.activemq.jndi.ActiveMQInitialContextFactory&quot;);
	props.setProperty(Context.PROVIDER_URL,&quot;tcp://127.0.0.1:61616&quot;);	
	Context namingCtx = new InitialContext(props);
	ConnectionFactory cf = (ConnectionFactory)namingCtx.lookup(&quot;ConnectionFactory&quot;);
	Connection con = cf.createConnection();
	log.info(&quot;Creating connection to &quot;+Parameters);
	Destination dest = (Destination)namingCtx.lookup(Parameters);

	try {
		Session session = 
		      con.createSession(false, Session.AUTO_ACKNOWLEDGE);  // non-transacted session (more)
		MessageConsumer consumer = session.createConsumer(dest);
		consumer.setMessageListener(new MyMessageListener(session));
		log.info(&quot;Starting connection to &quot;+Parameters);
		con.start();                                             // start the connection (more)
		Thread.sleep(15000);
		session.close();
		log.info(&quot;Closed session&quot;);
	} finally {
		con.close();                                             // free all resources (more)	
	}
}
SampleResult.setResponseMessageOK();
SampleResult.setResponseData(&quot;Started Message Consumer&quot;, &quot;UTF-8&quot;);

class MyMessageListener implements MessageListener {
	Logger log = LoggerFactory.getLogger(MyMessageListener.class);
	Session session;
	public MyMessageListener(Session session) {
		this.session = session;
	}
	public void onMessage(Message message) {
	        TextMessage textMessage = (TextMessage) message;
	        try {
			Queue replyQueue = (Queue) message.getJMSReplyTo();
			log.info(&quot;Reply queue is: {}&quot;, replyQueue);
			log.info(&quot;Creating sender&quot;);
			QueueSender sender = session.createSender(replyQueue);
			log.info(&quot;Creating reply&quot;);
			TextMessage reply = session.createTextMessage(&quot;Reply to:&quot;+textMessage.getText());
			log.info(&quot;Sending reply&quot;);
			sender.send(reply);
			log.info(&quot;Tidyup sender - you could be processing many requests&quot;);
			sender.close();
	        } catch (JMSException e) {
	            log.error(&quot;Error replying to message&quot;, e);
	        }
	    }
}
</stringProp>
          <stringProp name="scriptLanguage">groovy</stringProp>
          <stringProp name="TestPlan.comments">Uses ReplyTo Queue to answer a message</stringProp>
        </JSR223Sampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="1700117006">Started Message Consumer</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-DefaultCorrelationId-TempQueue" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue0-tmp</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">true</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties"/>
          </elementProp>
          <boolProp name="JMSSampler.useResMsgIdAsCorrelId">true</boolProp>
          <stringProp name="TestPlan.comments">Test case where Request queue is empty meaning we&apos;ll wait for a reply on ReplyTo queue</stringProp>
          <intProp name="JMSSampler.communicationStyle">1</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="1806444283">Reply to:Test</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-CustomCorrelationId" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue1</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue">dynamicQueues/requestQueue1</stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-with-customer-correlationId</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <intProp name="JMSSampler.communicationStyle">1</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="620675290">Test-with-customer-correlationId</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-DifferentSelector" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue2</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue">dynamicQueues/requestQueue2</stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-with-customer-correlationId-and-jms-properties-no-matching-selector</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">NewsType</stringProp>
                <stringProp name="JMSProperty.value">Sports</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <stringProp name="JMSSampler.jmsSelector">NewsType=&apos;Opinion&apos;</stringProp>
          <intProp name="JMSSampler.communicationStyle">1</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="1882001775">No reply message received</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">true</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-SameSelector" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue3</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue">dynamicQueues/requestQueue3</stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-with-customer-correlationId-and-jms-properties-matching-selector</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">NewsType</stringProp>
                <stringProp name="JMSProperty.value">Sports</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <stringProp name="JMSSampler.jmsSelector">NewsType=&apos;Sports&apos;</stringProp>
          <intProp name="JMSSampler.communicationStyle">1</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="451718395">Test-with-customer-correlationId-and-jms-properties-matching-selector</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-RequestOnly" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue4</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-send-only</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <intProp name="JMSSampler.communicationStyle">0</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1549895784">Oneway request has no response data</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <JSR223Sampler guiclass="TestBeanGUI" testclass="JSR223Sampler" testname="JSS-ConsumePreviousMessage" enabled="true">
          <stringProp name="cacheKey">true</stringProp>
          <stringProp name="filename"></stringProp>
          <stringProp name="parameters"></stringProp>
          <stringProp name="script">import org.apache.activemq.ActiveMQConnectionFactory;
import javax.jms.*;
import javax.naming.InitialContext;
import javax.naming.Context;
import java.util.Properties;

Properties props = new Properties();
props.setProperty(Context.INITIAL_CONTEXT_FACTORY,&quot;org.apache.activemq.jndi.ActiveMQInitialContextFactory&quot;);
props.setProperty(Context.PROVIDER_URL,&quot;tcp://127.0.0.1:61616&quot;);
Context namingCtx = new InitialContext(props);
ConnectionFactory cf = (ConnectionFactory)namingCtx.lookup(&quot;ConnectionFactory&quot;);
Connection con = cf.createConnection();
Destination dest = (Destination)namingCtx.lookup(&quot;dynamicQueues/requestQueue4&quot;);

try {
  Session session = 
      con.createSession(false, Session.AUTO_ACKNOWLEDGE);  // non-transacted session (more)

  MessageConsumer consumer = session.createConsumer(dest);

  con.start();                                             // start the connection (more)
                                         // run forever
    Message msg = consumer.receive();                      // blocking! (more)
    if  (msg instanceof TextMessage) {
 		SampleResult.setResponseMessageOK();
 		TextMessage tm = (TextMessage) msg;
	    SampleResult.setResponseData(&quot;Received : &quot;+tm.getText(), &quot;UTF-8&quot;);
    }
 	else {
 		SampleResult.setResponseMessageKO();
	    SampleResult.setResponseData(&quot;No message received&quot;, &quot;UTF-8&quot;);
 	}
}
finally {
  con.close();                                             // free all resources (more)
}</stringProp>
          <stringProp name="scriptLanguage">groovy</stringProp>
        </JSR223Sampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-487953317">Received : Test-send-only</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-RequestOnly" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue5</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-send-only-for-count-and-read</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <intProp name="JMSSampler.communicationstyle">0</intProp>
          <intProp name="JMSSampler.communicationStyle">0</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1549895784">Oneway request has no response data</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-Browse" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue5</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data"></stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <intProp name="JMSSampler.communicationstyle">3</intProp>
          <intProp name="JMSSampler.communicationStyle">3</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1029016402">requestQueue5 has 1 messages</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-Read" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue5</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout">1000</stringProp>
          <stringProp name="HTTPSamper.xml_data"></stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties"/>
          </elementProp>
          <intProp name="JMSSampler.communicationstyle">2</intProp>
          <intProp name="JMSSampler.communicationStyle">2</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1086280699">Test-send-only-for-count-and-read</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-RequestOnlyForClear" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue6</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-send-only-for-clear</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <intProp name="JMSSampler.communicationstyle">0</intProp>
          <intProp name="JMSSampler.communicationStyle">0</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1549895784">Oneway request has no response data</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-Clear" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue6</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout">100</stringProp>
          <stringProp name="HTTPSamper.xml_data"></stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties"/>
          </elementProp>
          <intProp name="JMSSampler.communicationstyle">4</intProp>
          <stringProp name="JMSSampler.expiration">1000</stringProp>
          <stringProp name="JMSSampler.jmsNumberOfSamplesToAggregate"></stringProp>
          <intProp name="JMSSampler.communicationStyle">4</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="2008037952">requestQueue6: 1 message(s) removed</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-BrowseAfterClear" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue6</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">false</boolProp>
          <stringProp name="JMSSampler.timeout"></stringProp>
          <stringProp name="HTTPSamper.xml_data">Test-send-only-for-count-and-read</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">JMSCorrelationId</stringProp>
                <stringProp name="JMSProperty.value">MsgId-${__time(,)}</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <intProp name="JMSSampler.communicationstyle">3</intProp>
          <intProp name="JMSSampler.communicationStyle">3</intProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1343037074">requestQueue6 has 0 messages</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <JMSSampler guiclass="JMSSamplerGui" testclass="JMSSampler" testname="JMS-P2P-Timeout" enabled="true">
          <stringProp name="JMSSampler.queueconnectionfactory">ConnectionFactory</stringProp>
          <stringProp name="JMSSampler.SendQueue">dynamicQueues/requestQueue7</stringProp>
          <stringProp name="JMSSampler.ReceiveQueue"></stringProp>
          <intProp name="JMSSampler.communicationStyle">1</intProp>
          <boolProp name="JMSSampler.isNonPersistent">false</boolProp>
          <boolProp name="JMSSampler.useReqMsgIdAsCorrelId">true</boolProp>
          <stringProp name="JMSSampler.timeout">2000</stringProp>
          <stringProp name="JMSSampler.jmsNumberOfSamplesToAggregate"></stringProp>
          <stringProp name="HTTPSamper.xml_data">test</stringProp>
          <stringProp name="JMSSampler.initialContextFactory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="JMSSampler.contextProviderUrl">tcp://localhost:61616</stringProp>
          <elementProp name="JMSSampler.jndiProperties" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <elementProp name="arguments" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties"/>
          </elementProp>
          <boolProp name="JMSSampler.useResMsgIdAsCorrelId">true</boolProp>
        </JMSSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="RA_noMessage" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="1882001775">No reply message received</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">true</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
      </hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="TG-JMS-PS" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </ThreadGroup>
      <hashTree>
        <PublisherSampler guiclass="JMSPublisherGui" testclass="PublisherSampler" testname="JMS Publisher-NonDurable" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic1</stringProp>
          <stringProp name="jms.expiration"></stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="jms.priority"></stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <stringProp name="jms.text_message">Test Topic</stringProp>
          <stringProp name="jms.input_file"></stringProp>
          <stringProp name="jms.random_path"></stringProp>
          <stringProp name="jms.config_choice">jms_use_text</stringProp>
          <stringProp name="jms.config_msg_type">jms_text_message</stringProp>
          <stringProp name="jms.iterations">1</stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <elementProp name="jms.jmsProperties" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">prop1</stringProp>
                <stringProp name="JMSProperty.value">value1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propInt</stringProp>
                <stringProp name="JMSProperty.value">1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Integer</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propBoolean</stringProp>
                <stringProp name="JMSProperty.value">true</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Boolean</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propDouble</stringProp>
                <stringProp name="JMSProperty.value">1.123</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Double</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propFloat</stringProp>
                <stringProp name="JMSProperty.value">1.2</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Float</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <boolProp name="jms.destination_static">false</boolProp>
        </PublisherSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1719216023">1 messages published</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-NonDurable" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic1</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_receive</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="1506174364">1 message(s) received successfully of 1 expected</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-2063475679">Test Topic</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="812041149">Properties:
prop1	value1
propBoolean	true
propInt	1
propDouble	1.123
propFloat	1.2</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_headers</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
      </hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="TG-JMS-PS-Selector-receive" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
        <stringProp name="TestPlan.comments">Persistent Publish / Subscribe with selectors</stringProp>
      </ThreadGroup>
      <hashTree>
        <PublisherSampler guiclass="JMSPublisherGui" testclass="PublisherSampler" testname="JMS Publisher-Persistent" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2</stringProp>
          <stringProp name="jms.expiration"></stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="jms.priority"></stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <stringProp name="jms.text_message">Test Topic</stringProp>
          <stringProp name="jms.input_file"></stringProp>
          <stringProp name="jms.random_path"></stringProp>
          <stringProp name="jms.config_choice">jms_use_text</stringProp>
          <stringProp name="jms.config_msg_type">jms_text_message</stringProp>
          <stringProp name="jms.iterations">1</stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <elementProp name="jms.jmsProperties" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">prop1</stringProp>
                <stringProp name="JMSProperty.value">value1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propInt</stringProp>
                <stringProp name="JMSProperty.value">1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Integer</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propBoolean</stringProp>
                <stringProp name="JMSProperty.value">true</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Boolean</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propDouble</stringProp>
                <stringProp name="JMSProperty.value">1.123</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Double</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propFloat</stringProp>
                <stringProp name="JMSProperty.value">1.2</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Float</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <boolProp name="jms.destination_static">false</boolProp>
        </PublisherSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1719216023">1 messages published</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-NonMatchingSelector" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_receive</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Non matching selector</stringProp>
          <stringProp name="jms.selector">propInt = 2</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="51512">404</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_code</stringProp>
            <boolProp name="Assertion.assume_success">true</boolProp>
            <intProp name="Assertion.test_type">8</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-at-startup-onMessage" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_receive</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Matching selector</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
          <stringProp name="jms.selector">propInt = 1</stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-2063475679">Test Topic</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
      </hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="TG-JMS-PS-Selector-onMessage" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
        <stringProp name="TestPlan.comments">Persistent Publish / Subscribe</stringProp>
      </ThreadGroup>
      <hashTree>
        <PublisherSampler guiclass="JMSPublisherGui" testclass="PublisherSampler" testname="JMS Publisher-Persistent" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2c</stringProp>
          <stringProp name="jms.expiration"></stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="jms.priority"></stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <stringProp name="jms.text_message">Test Topic</stringProp>
          <stringProp name="jms.input_file"></stringProp>
          <stringProp name="jms.random_path"></stringProp>
          <stringProp name="jms.config_choice">jms_use_text</stringProp>
          <stringProp name="jms.config_msg_type">jms_text_message</stringProp>
          <stringProp name="jms.iterations">1</stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <elementProp name="jms.jmsProperties" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">prop1</stringProp>
                <stringProp name="JMSProperty.value">value1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propInt</stringProp>
                <stringProp name="JMSProperty.value">1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Integer</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propBoolean</stringProp>
                <stringProp name="JMSProperty.value">true</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Boolean</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propDouble</stringProp>
                <stringProp name="JMSProperty.value">1.123</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Double</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propFloat</stringProp>
                <stringProp name="JMSProperty.value">1.2</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Float</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <boolProp name="jms.destination_static">false</boolProp>
        </PublisherSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1719216023">1 messages published</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-NonMatchingSelector-receive" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2c</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_on_message</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Non matching selector</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
          <stringProp name="jms.selector">propInt = 2</stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="51512">404</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_code</stringProp>
            <boolProp name="Assertion.assume_success">true</boolProp>
            <intProp name="Assertion.test_type">8</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">1000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-MatchingSelector-receive" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2c</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_on_message</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Matching selector</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
          <stringProp name="jms.selector">propInt = 1</stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-2063475679">Test Topic</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
      </hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="TG-JMS-PS-Durable" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
        <stringProp name="TestPlan.comments">Persistent Publish / Subscribe</stringProp>
      </ThreadGroup>
      <hashTree>
        <PublisherSampler guiclass="JMSPublisherGui" testclass="PublisherSampler" testname="JMS Publisher-Persistent" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2d</stringProp>
          <stringProp name="jms.expiration"></stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="jms.priority"></stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <stringProp name="jms.text_message">Test Durable Topic Message</stringProp>
          <stringProp name="jms.input_file"></stringProp>
          <stringProp name="jms.random_path"></stringProp>
          <stringProp name="jms.config_choice">jms_use_text</stringProp>
          <stringProp name="jms.config_msg_type">jms_text_message</stringProp>
          <stringProp name="jms.iterations">1</stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <elementProp name="jms.jmsProperties" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">prop1</stringProp>
                <stringProp name="JMSProperty.value">value1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propInt</stringProp>
                <stringProp name="JMSProperty.value">1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Integer</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propBoolean</stringProp>
                <stringProp name="JMSProperty.value">true</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Boolean</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propDouble</stringProp>
                <stringProp name="JMSProperty.value">1.123</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Double</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propFloat</stringProp>
                <stringProp name="JMSProperty.value">1.2</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Float</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <boolProp name="jms.destination_static">false</boolProp>
        </PublisherSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1719216023">1 messages published</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <TestAction guiclass="TestActionGui" testclass="TestAction" testname="Think Time" enabled="true">
          <intProp name="ActionProcessor.action">1</intProp>
          <intProp name="ActionProcessor.target">0</intProp>
          <stringProp name="ActionProcessor.duration">0</stringProp>
        </TestAction>
        <hashTree>
          <UniformRandomTimer guiclass="UniformRandomTimerGui" testclass="UniformRandomTimer" testname="Pause" enabled="true">
            <stringProp name="ConstantTimer.delay">5000</stringProp>
            <stringProp name="RandomTimer.range">100</stringProp>
          </UniformRandomTimer>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-Durable" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic2d</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_receive</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Matching selector</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
          <stringProp name="jms.durableSubscriptionId">jmeter-${__machineIP()}-id</stringProp>
          <stringProp name="jms.clientId">jmeter-${__machineIP()}</stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="1154304067">Test Durable Topic Message</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
      </hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" testname="TG-JMS-PS-Selector-Non-Persistent" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </ThreadGroup>
      <hashTree>
        <PublisherSampler guiclass="JMSPublisherGui" testclass="PublisherSampler" testname="JMS Publisher-NonPersistent" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic3</stringProp>
          <stringProp name="jms.expiration"></stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="jms.priority"></stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <stringProp name="jms.text_message">Test Topic</stringProp>
          <stringProp name="jms.input_file"></stringProp>
          <stringProp name="jms.random_path"></stringProp>
          <stringProp name="jms.config_choice">jms_use_text</stringProp>
          <stringProp name="jms.config_msg_type">jms_text_message</stringProp>
          <stringProp name="jms.iterations">1</stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <elementProp name="jms.jmsProperties" elementType="JMSProperties">
            <collectionProp name="JMSProperties.properties">
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">prop1</stringProp>
                <stringProp name="JMSProperty.value">value1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.String</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propInt</stringProp>
                <stringProp name="JMSProperty.value">1</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Integer</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propBoolean</stringProp>
                <stringProp name="JMSProperty.value">true</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Boolean</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propDouble</stringProp>
                <stringProp name="JMSProperty.value">1.123</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Double</stringProp>
              </elementProp>
              <elementProp name="" elementType="JMSProperty">
                <stringProp name="JMSProperty.name">propFloat</stringProp>
                <stringProp name="JMSProperty.value">1.2</stringProp>
                <stringProp name="JMSProperty.type">java.lang.Float</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <boolProp name="jms.destination_static">false</boolProp>
          <boolProp name="jms.non_persistent">true</boolProp>
        </PublisherSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-1719216023">1 messages published</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_message</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-NP-EachSample" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic3</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_receive</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Will not receive message as messages are Non Persistent and  it is initialized for each sample</stringProp>
          <stringProp name="jms.selector">propInt = 1</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
          <boolProp name="jms.destination_static">false</boolProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="51512">404</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_code</stringProp>
            <boolProp name="Assertion.assume_success">true</boolProp>
            <intProp name="Assertion.test_type">8</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
        <SubscriberSampler guiclass="JMSSubscriberGui" testclass="SubscriberSampler" testname="JMS Subscriber-NP-OnStartup" enabled="true">
          <stringProp name="jms.jndi_properties">false</stringProp>
          <stringProp name="jms.initial_context_factory">org.apache.activemq.jndi.ActiveMQInitialContextFactory</stringProp>
          <stringProp name="jms.provider_url">tcp://127.0.0.1:61616</stringProp>
          <stringProp name="jms.connection_factory">ConnectionFactory</stringProp>
          <stringProp name="jms.topic">dynamicTopics/requestTopic3</stringProp>
          <stringProp name="jms.security_principle"></stringProp>
          <stringProp name="jms.security_credentials"></stringProp>
          <boolProp name="jms.authenticate">false</boolProp>
          <stringProp name="jms.iterations">1</stringProp>
          <stringProp name="jms.read_response">true</stringProp>
          <stringProp name="jms.client_choice">jms_subscriber_receive</stringProp>
          <stringProp name="jms_error_reconnect_on_codes"></stringProp>
          <stringProp name="TestPlan.comments">Will receive message as messages are Non Persistent but it is initialized on startup</stringProp>
          <stringProp name="jms.timeout">3000</stringProp>
          <stringProp name="jms.selector">propInt = 1</stringProp>
        </SubscriberSampler>
        <hashTree>
          <ResponseAssertion guiclass="AssertionGui" testclass="ResponseAssertion" testname="Response Assertion" enabled="true">
            <collectionProp name="Asserion.test_strings">
              <stringProp name="-2063475679">Test Topic</stringProp>
            </collectionProp>
            <stringProp name="Assertion.test_field">Assertion.response_data</stringProp>
            <boolProp name="Assertion.assume_success">false</boolProp>
            <intProp name="Assertion.test_type">16</intProp>
          </ResponseAssertion>
          <hashTree/>
        </hashTree>
      </hashTree>
      <PostThreadGroup guiclass="PostThreadGroupGui" testclass="PostThreadGroup" testname="tearDown Thread Group" enabled="true">
        <stringProp name="ThreadGroup.on_sample_error">continue</stringProp>
        <elementProp name="ThreadGroup.main_controller" elementType="LoopController" guiclass="LoopControlPanel" testclass="LoopController" testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </PostThreadGroup>
      <hashTree>
        <JSR223Sampler guiclass="TestBeanGUI" testclass="JSR223Sampler" testname="BSS_stopActiveMQ" enabled="true">
          <stringProp name="scriptLanguage">groovy</stringProp>
          <stringProp name="parameters"></stringProp>
          <stringProp name="filename"></stringProp>
          <stringProp name="cacheKey">true</stringProp>
          <stringProp name="script">import org.apache.activemq.broker.BrokerService;
import org.apache.jmeter.util.JMeterUtils;
import org.apache.commons.io.FileUtils;

BrokerService broker = props.get(&quot;ACTIVEMQ_BROKER&quot;);
Thread.start {
  // The delay is to allow for JMS Publishers to close resources in testEnded event
  // Note: JMeter warns for non-daemon threads which are active
  // So the sleep duration should be less than 2sec
  // Otherwise &quot;The following non-daemon threads are still running&quot; is printed
  sleep(700)
  broker.stop()
  FileUtils.deleteDirectory(new File(JMeterUtils.getJMeterHome(), &quot;bin/activemq-data&quot;))
}
</stringProp>
        </JSR223Sampler>
        <hashTree/>
      </hashTree>
      <ResultCollector guiclass="ViewResultsFullVisualizer" testclass="ResultCollector" testname="View Results Tree" enabled="true">
        <boolProp name="ResultCollector.error_logging">false</boolProp>
        <objProp>
          <name>saveConfig</name>
          <value class="SampleSaveConfiguration">
            <time>false</time>
            <latency>false</latency>
            <timestamp>false</timestamp>
            <success>true</success>
            <label>true</label>
            <code>true</code>
            <message>true</message>
            <threadName>true</threadName>
            <dataType>true</dataType>
            <encoding>false</encoding>
            <assertions>false</assertions>
            <subresults>false</subresults>
            <responseData>false</responseData>
            <samplerData>false</samplerData>
            <xml>false</xml>
            <fieldNames>true</fieldNames>
            <responseHeaders>false</responseHeaders>
            <requestHeaders>false</requestHeaders>
            <responseDataOnError>false</responseDataOnError>
            <saveAssertionResultsFailureMessage>false</saveAssertionResultsFailureMessage>
            <assertionsResultsToSave>0</assertionsResultsToSave>
            <threadCounts>true</threadCounts>
            <sampleCount>true</sampleCount>
          </value>
        </objProp>
        <stringProp name="filename">JMS_TESTS.csv</stringProp>
        <stringProp name="TestPlan.comments">Clear messages on Send Queue requestQueue6:1 message(s) removed</stringProp>
      </ResultCollector>
      <hashTree/>
      <ResultCollector guiclass="SimpleDataWriter" testclass="ResultCollector" testname="Simple Data Writer" enabled="true">
        <boolProp name="ResultCollector.error_logging">false</boolProp>
        <objProp>
          <name>saveConfig</name>
          <value class="SampleSaveConfiguration">
            <time>false</time>
            <latency>false</latency>
            <timestamp>false</timestamp>
            <success>true</success>
            <label>true</label>
            <code>true</code>
            <message>true</message>
            <threadName>true</threadName>
            <dataType>true</dataType>
            <encoding>false</encoding>
            <assertions>true</assertions>
            <subresults>true</subresults>
            <responseData>false</responseData>
            <samplerData>false</samplerData>
            <xml>true</xml>
            <fieldNames>false</fieldNames>
            <responseHeaders>false</responseHeaders>
            <requestHeaders>false</requestHeaders>
            <responseDataOnError>false</responseDataOnError>
            <saveAssertionResultsFailureMessage>false</saveAssertionResultsFailureMessage>
            <assertionsResultsToSave>0</assertionsResultsToSave>
            <threadCounts>true</threadCounts>
            <sampleCount>true</sampleCount>
          </value>
        </objProp>
        <stringProp name="filename">JMS_TESTS.xml</stringProp>
      </ResultCollector>
      <hashTree/>
    </hashTree>
  </hashTree>
</jmeterTestPlan>
