private JMeterEngine getClientEngine(String address, HashTree testTree) { JMeterEngine engine; try { engine = createEngine(address); engine.configure(testTree); if (!remoteProps.isEmpty()) { engine.setProperties(remoteProps); } return engine; } catch (Exception ex) { log.error("Failed to create engine at {}", address, ex); JMeterUtils.reportErrorToUser(ex.getMessage(), JMeterUtils.getResString("remote_error_init") + ": " + address); // $NON-NLS-1$ $NON-NLS-2$ return null; } }
private HashTree loadJMX(File file) throws Exception { HashTree tree = SaveService.loadTree(file); // unfortunately core JMeter code does not throw exception, we may only guess... if (tree == null) { throw new TestPlanBrokenException("There was problems loading test plan. Please investigate error messages above."); } JMeter.convertSubTree(tree); // Remove the disabled items JMeterEngine engine = new StandardJMeterEngine(); engine.configure(tree); return tree; }
private HashTree loadJMX(InputStream reader) throws Exception { HashTree tree = SaveService.loadTree(reader); // unfortunately core JMeter code does not throw exception, we may only guess... if (tree == null) { throw new TestPlanBrokenException("There was problems loading test plan. Please investigate error messages above."); } JMeter.convertSubTree(tree); // Remove the disabled items JMeterEngine engine = new StandardJMeterEngine(); engine.configure(tree); return tree; }
JMeterUtils.setProperty(JMeterUtils.THREAD_GROUP_DISTRIBUTED_PREFIX_PROPERTY_NAME, hostAndPort); backingEngine = new StandardJMeterEngine(hostAndPort); backingEngine.configure(testTree); // sets active = true
if (!remoteStart) { JMeterEngine engine = new StandardJMeterEngine(); engine.configure(tree); long now=System.currentTimeMillis(); println("Starting the test @ "+new Date(now)+" ("+now+")");