ASF Bugzilla – Attachment 32686 Details for
Bug 57858
sampleEnd called twice by HTTPHC4Impl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Only call sampleEnd, when it is not already set
003.diff (text/plain), 1.44 KB, created by
Felix Schumacher
on 2015-04-26 11:43:42 UTC
(
hide
)
Description:
Only call sampleEnd, when it is not already set
Filename:
MIME Type:
Creator:
Felix Schumacher
Created:
2015-04-26 11:43:42 UTC
Size:
1.44 KB
patch
obsolete
>diff --git a/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java b/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java >index 19199ed..f99ef9b 100644 >--- a/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java >+++ b/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java >@@ -411,15 +411,22 @@ public class HTTPHC4Impl extends HTTPHCAbstractImpl { > res = resultProcessing(areFollowingRedirect, frameDepth, res); > > } catch (IOException e) { >- res.sampleEnd(); > log.debug("IOException", e); >- // pick up headers if failed to execute the request >+ if (res.getEndTime() == 0) { >+ res.sampleEnd(); >+ } >+ // pick up headers if failed to execute the request >+ if (res.getRequestHeaders() != null) { >+ log.debug("Overwriting request old headers: " + res.getRequestHeaders()); >+ } > res.setRequestHeaders(getConnectionHeaders((HttpRequest) localContext.getAttribute(ExecutionContext.HTTP_REQUEST))); > errorResult(e, res); > return res; > } catch (RuntimeException e) { >- res.sampleEnd(); > log.debug("RuntimeException", e); >+ if (res.getEndTime() == 0) { >+ res.sampleEnd(); >+ } > errorResult(e, res); > return res; > } finally {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 57858
: 32686