2013-11-25 70 views
1

Jmeter腳本在apache-jmeter2.8上運行良好。我最近升級到apache-jmeter-2.10,並開始獲得Null Point例外。Apache jmeter - 2.10 - 運行現有腳本時出現空點異常

我恢復到apache-jmeter2.8並且腳本正常工作。

 java.lang.NullPointerException 
at org.apache.jorphan.util.JOrphanUtils.replaceAllChars(JOrphanUtils.java:264) 
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.encodeSpaces(HTTPSamplerBase.java:1332) 
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.followRedirects(HTTPSamplerBase.java:1404) 
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.resultProcessing(HTTPSamplerBase.java:1482) 
at org.apache.jmeter.protocol.http.sampler.HTTPAbstractImpl.resultProcessing(HTTPAbstractImpl.java:306) 
at org.apache.jmeter.protocol.http.sampler.HTTPHC4Impl.sample(HTTPHC4Impl.java:381) 
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerProxy.sample(HTTPSamplerProxy.java:74) 
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1105) 
at org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase.sample(HTTPSamplerBase.java:1094) 
at org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:429) 
at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:257) 
at java.lang.Thread.run(Unknown Source) 

該腳本是通用登錄腳本,並在嘗試發佈時發生失敗。

讓我知道你是否需要更多信息。

回答

2

您可能會面臨這種已知的bug已被固定在每晚構建:

作爲一種變通方法,嘗試改變HTTP實現對Java,而不是HttpClient4的實施。

如果你想給夜間生成一試,請參閱:

http://jmeter.apache.org/nightly.html 

閱讀:

安裝JMeter的運行

下載_bin和_lib文件

拆開歸檔到相同的目錄結構中

其他檔案不需要運行JMeter。

+1

將http實現更改爲Java並且工作正常。感謝。 – user1984004PRI

0

上述錯誤已在2.11版本中解決。下載並使用最新版本的jmeter 2.11並檢查你的腳本。

沒有必要去夜間生成。