You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jmeter.apache.org by pm...@apache.org on 2017/10/23 18:13:00 UTC

svn commit: r1813051 - /jmeter/trunk/bin/testfiles/JMS_TESTS.jmx

Author: pmouawad
Date: Mon Oct 23 18:13:00 2017
New Revision: 1813051

URL: http://svn.apache.org/viewvc?rev=1813051&view=rev
Log:
Try to find root cause of Windows failures

Modified:
    jmeter/trunk/bin/testfiles/JMS_TESTS.jmx

Modified: jmeter/trunk/bin/testfiles/JMS_TESTS.jmx
URL: http://svn.apache.org/viewvc/jmeter/trunk/bin/testfiles/JMS_TESTS.jmx?rev=1813051&r1=1813050&r2=1813051&view=diff
==============================================================================
--- jmeter/trunk/bin/testfiles/JMS_TESTS.jmx (original)
+++ jmeter/trunk/bin/testfiles/JMS_TESTS.jmx Mon Oct 23 18:13:00 2017
@@ -30,11 +30,19 @@
 import org.apache.activemq.broker.BrokerFactory;
 import org.apache.jmeter.util.JMeterUtils;
 import org.apache.commons.io.FileUtils;
+import java.io.File;
 
-FileUtils.deleteDirectory(new File(JMeterUtils.getJMeterHome(), "bin/activemq-data"));
-BrokerService broker = BrokerFactory.createBroker("xbean:file:"+JMeterUtils.getJMeterHome()+ "/bin/testfiles/activemq.xml", true);
-bsh.shared.myMap = new HashMap();
-bsh.shared.myMap.put("ACTIVEMQ_BROKER", broker);
+File file = new File(JMeterUtils.getJMeterHome(), "bin/activemq-data");
+log.info("Deleting {}", file);
+FileUtils.deleteDirectory(file);
+log.info("Creating activemq config from {}", JMeterUtils.getJMeterHome()+ "/bin/testfiles/activemq.xml");
+try {
+	BrokerService broker = BrokerFactory.createBroker("xbean:file:"+JMeterUtils.getJMeterHome()+ "/bin/testfiles/activemq.xml", true);
+	bsh.shared.myMap = new HashMap();
+	bsh.shared.myMap.put("ACTIVEMQ_BROKER", broker);
+} catch(Exception ex) {
+	log.error("Error configuring ActiveMQ", ex);
+}
 </stringProp>
           <stringProp name="BeanShellSampler.filename"></stringProp>
           <stringProp name="BeanShellSampler.parameters"></stringProp>