You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jmeter.apache.org by pm...@apache.org on 2015/06/13 23:17:48 UTC
svn commit: r1685333 - in /jmeter/trunk:
src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java
src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java
xdocs/changes.xml
Author: pmouawad
Date: Sat Jun 13 21:17:47 2015
New Revision: 1685333
URL: http://svn.apache.org/r1685333
Log:
Bug 57956 - The hc.parameters reference in jmeter.properties doesn't work when JMeter is not started in bin
Bugzilla Id: 57956
Modified:
jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java
jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java
jmeter/trunk/xdocs/changes.xml
Modified: jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java?rev=1685333&r1=1685332&r2=1685333&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java (original)
+++ jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java Sat Jun 13 21:17:47 2015
@@ -64,6 +64,7 @@ import org.apache.commons.httpclient.par
import org.apache.commons.httpclient.params.HttpParams;
import org.apache.commons.httpclient.protocol.Protocol;
import org.apache.commons.io.input.CountingInputStream;
+import org.apache.jmeter.NewDriver;
import org.apache.jmeter.protocol.http.control.AuthManager;
import org.apache.jmeter.protocol.http.control.Authorization;
import org.apache.jmeter.protocol.http.control.CacheManager;
@@ -136,7 +137,10 @@ public class HTTPHC3Impl extends HTTPHCA
// Process Commons HttpClient parameters file
String file=JMeterUtils.getProperty("httpclient.parameters.file"); // $NON-NLS-1$
if (file != null) {
- HttpClientDefaultParameters.load(file, params);
+ log.info("Loading httpclient parameters file from:"+file);
+ HttpClientDefaultParameters.load(NewDriver.getJMeterDir() + File.separator
+ + "bin" + File.separator // $NON-NLS-1$
+ + file, params);
}
// If the pre-emptive parameter is undefined, then we can set it as needed
Modified: jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java?rev=1685333&r1=1685332&r2=1685333&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java (original)
+++ jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java Sat Jun 13 21:17:47 2015
@@ -105,6 +105,7 @@ import org.apache.http.protocol.BasicHtt
import org.apache.http.protocol.ExecutionContext;
import org.apache.http.protocol.HTTP;
import org.apache.http.protocol.HttpContext;
+import org.apache.jmeter.NewDriver;
import org.apache.jmeter.protocol.http.control.AuthManager;
import org.apache.jmeter.protocol.http.control.CacheManager;
import org.apache.jmeter.protocol.http.control.CookieManager;
@@ -213,7 +214,10 @@ public class HTTPHC4Impl extends HTTPHCA
// Process Apache HttpClient parameters file
String file=JMeterUtils.getProperty("hc.parameters.file"); // $NON-NLS-1$
if (file != null) {
- HttpClientDefaultParameters.load(file, DEFAULT_HTTP_PARAMS);
+ log.info("Loading hc parameters file from:"+file);
+ HttpClientDefaultParameters.load(NewDriver.getJMeterDir() + File.separator
+ + "bin" + File.separator // $NON-NLS-1$
+ + file, DEFAULT_HTTP_PARAMS);
}
// Set up HTTP scheme override if necessary
@@ -416,7 +420,7 @@ public class HTTPHC4Impl extends HTTPHCA
if (res.getEndTime() == 0) {
res.sampleEnd();
}
- // pick up headers if failed to execute the request
+ // pick up headers if failed to execute the request
if (res.getRequestHeaders() != null) {
log.debug("Overwriting request old headers: " + res.getRequestHeaders());
}
Modified: jmeter/trunk/xdocs/changes.xml
URL: http://svn.apache.org/viewvc/jmeter/trunk/xdocs/changes.xml?rev=1685333&r1=1685332&r2=1685333&view=diff
==============================================================================
--- jmeter/trunk/xdocs/changes.xml (original)
+++ jmeter/trunk/xdocs/changes.xml Sat Jun 13 21:17:47 2015
@@ -128,6 +128,7 @@ Summary
<li><bug>57806</bug>"audio/x-mpegurl" mime type is erroneously considered as binary by ViewResultsTree. Contributed by Ubik Load Pack (support at ubikloadpack.com)</li>
<li><bug>57858</bug>Don't call sampleEnd twice in HTTPHC4Impl when a RuntimeException or an IOException occurs in the sample method.</li>
<li><bug>57921</bug>HTTP/1.1 without keep-alive "Connection" response header no longer uses infinite keep-alive.</li>
+ <li><bug>57956</bug>The hc.parameters reference in jmeter.properties doesn't work when JMeter is not started in bin.</li>
</ul>
<h3>Other Samplers</h3>