To track the latency of multiple requests forming one single transaction (inside runTest()), we'd like to use sub-results. Thus, JMeter is started with -Jjmeter.save.saveservice.subresults=true and -Jjmeter.save.saveservice.output_format=xml. This saves the results in an XML file, which we'd like to read to store the values in our internal load test result DB.
I can load the SampleResults objects back fine with the following line. However, the loadElement() method is marked with "Used by Test code", which mights suggest that it should not be relied on? TestResultWrapper results = (TestResultWrapper) org.apache.jmeter.save.SaveService.loadElement(inputStream); Furthermore, using the SaveService class within another application is slightly inconvenient, since it depends on the properties file ".../bin/saveservice.properties". This file is loaded inside a global static block (a common patterned throughout the JMeter code). JMeterUtils.setJMeterHome() can be used to set the base directory, but the code in our internal data application would start to look ugly... Is there another sanctioned way to read back the XML results file? Duplicating the functionality within SaveService will not buy us much, since the saveservice.properties file contains the xml to class mappings. Or should we ignore the SampleResultConverter / SaveService completely, and just write our own XML loader and parser. That would be a bit of a shame, since the line above is all that is needed. Have anybody else worked with this? Regards, Havard -- --->Google Switzerland GmbH Identifikationsnummer: CH-020.4.028.116-1<----
