我一直在 jMeter 中制定测试计划,并将其保存,现在无法打开它。事实证明 .jmx 文件已损坏。这是错误日志:
---- Debugging information ----
message : : no more data available - expected end tags </intProp></ConstantThroughputTimer></hashTree></hashTree></hashTree></hashTree></hashTree></jmeterTestPlan> to close start tag <intProp> from line 464 and start tag <ConstantThroughputTimer> from line 463 and start tag <hashTree> from line 429 and start tag <hashTree> from line 387 and start tag <hashTree> from line 35 and start tag <hashTree> from line 19 and start tag <hashTree> from line 3 and start tag <jmeterTestPlan> from line 2, parser stopped on TEXT seen ...</intProp>\n <doubleProp... @465:26
cause-exception : com.thoughtworks.xstream.io.StreamException
cause-message : : no more data available - expected end tags </intProp></ConstantThroughputTimer></hashTree></hashTree></hashTree></hashTree></hashTree></jmeterTestPlan> to close start tag <intProp> from line 464 and start tag <ConstantThroughputTimer> from line 463 and start tag <hashTree> from line 429 and start tag <hashTree> from line 387 and start tag <hashTree> from line 35 and start tag <hashTree> from line 19 and start tag <hashTree> from line 3 and start tag <jmeterTestPlan> from line 2, parser stopped on TEXT seen ...</intProp>\n <doubleProp... @465:26
class : org.apache.jmeter.timers.ConstantThroughputTimer
required-type : org.apache.jmeter.timers.ConstantThroughputTimer
converter-type : org.apache.jmeter.save.converters.TestElementConverter
path : /jmeterTestPlan/hashTree/hashTree/hashTree/hashTree[10]/hashTree/ConstantThroughputTimer
line number : 465
class[1] : org.apache.jorphan.collections.ListedHashTree
converter-type[1] : org.apache.jmeter.save.converters.HashTreeConverter
所以我检查了 jmx 文件,果然,就在 ConstantThroughputTimer 之后,配置的下半部分丢失了。诡异的!不知道为什么会发生这种情况。 有其他人经历过这种情况或知道如何解决该问题以免再次发生吗?
作为引用,我在 Windows 7 上使用 jMeter 2.11 以及 JDK1.8.0_05 和 JRE8。
最佳答案
我注意到类似的事情,使用 jmeter build 2.11.r1554548(构建于 2013 年 12 月 31 日)保存后,我的测试计划被损坏。看起来像 jmeter 错误。
解决方法是从测试计划中删除 ConstantThroughputTimer。保存效果完美。
我尝试使用 jmeter 的最新夜间版本。我下载了 apache-jmeter-r1613102(构建于 2014 年 7 月 18 日),但测试计划中的 ConstantThroughputTimer 仍在破坏测试计划文件。
关于apache - JMeter jmx 文件损坏,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24013043/