You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jmeter.apache.org by se...@apache.org on 2012/11/22 00:42:54 UTC

svn commit: r1412363 - 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: sebb
Date: Wed Nov 21 23:42:53 2012
New Revision: 1412363

URL: http://svn.apache.org/viewvc?rev=1412363&view=rev
Log:
Request tab does not show headers if request fails
Bugzilla Id: 54187

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=1412363&r1=1412362&r2=1412363&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 Wed Nov 21 23:42:53 2012
@@ -339,10 +339,14 @@ public class HTTPHC3Impl extends HTTPHCA
             return res;
         } catch (IllegalArgumentException e) { // e.g. some kinds of invalid URL
             res.sampleEnd();
+            // pick up headers if failed to execute the request
+            res.setRequestHeaders(getConnectionHeaders(httpMethod));
             errorResult(e, res);
             return res;
         } catch (IOException e) {
             res.sampleEnd();
+            // pick up headers if failed to execute the request
+            res.setRequestHeaders(getConnectionHeaders(httpMethod));
             errorResult(e, res);
             return res;
         } finally {

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=1412363&r1=1412362&r2=1412363&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 Wed Nov 21 23:42:53 2012
@@ -356,6 +356,8 @@ public class HTTPHC4Impl extends HTTPHCA
 
         } catch (IOException e) {
             res.sampleEnd();
+           // pick up headers if failed to execute the request
+            res.setRequestHeaders(getConnectionHeaders((HttpRequest) localContext.getAttribute(ExecutionContext.HTTP_REQUEST)));
             errorResult(e, res);
             return res;
         } catch (RuntimeException e) {

Modified: jmeter/trunk/xdocs/changes.xml
URL: http://svn.apache.org/viewvc/jmeter/trunk/xdocs/changes.xml?rev=1412363&r1=1412362&r2=1412363&view=diff
==============================================================================
--- jmeter/trunk/xdocs/changes.xml (original)
+++ jmeter/trunk/xdocs/changes.xml Wed Nov 21 23:42:53 2012
@@ -111,6 +111,7 @@ It has been removed so now size of these
 <ul>
 <li>Don't log spurious warning messages when using concurrent pool embedded downloads with Cache Manager or CookieManager</li>
 <li><bugzilla>54057</bugzilla>- Proxy option to set user and password at startup (-u and -a) not working with HTTPClient 4</li>
+<li><bugzilla>54187</bugzilla> - Request tab does not show headers if request fails</li>
 </ul>
 
 <h3>Other Samplers</h3>