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; }
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; }