https://bz.apache.org/bugzilla/show_bug.cgi?id=65884
Bug ID: 65884
Summary: GUI doesn't display response for multipart request
"manually" encoded
Product: JMeter
Version: unspecified
Hardware: PC
Status: NEW
Severity: major
Priority: P2
Component: HTTP
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: JMETER_5.5
When sending a multipart request without ticking the "Use multipart/form-data"
box and filling the Content-Type manually (because I need to test the server
with that specific request), the GUI generates an exception when trying to see
the response and doesn't display it.
Same problem with HTTP4Client and Java.
Same problem with a valid and invalid request.
Example:
HTTP Request:
POST
HTTP Header Manager:
Content-Type: multipart/form-data;
boundary=da0bad6c-05aa-4901-81d5-1f1da00a1d42
Body Data:
--da0bad6c-05aa-4901-81d5-1f1da00a1d42
Content-Type: application/pdf
Content-Disposition: form-data; name=file; filename=test.pdf
%PDF-1.4
%%EOF
--da0bad6c-05aa-4901-81d5-1f1da00a1d42--
The request is sent, the response is sent back.
In the GUI, the request is displayed normally, the response body & headers is
empty.
In the log console, we have an exception:
ERROR o.a.j.JMeter: Uncaught exception in thread
Thread[AWT-EventQueue-0,6,main]
java.lang.StringIndexOutOfBoundsException: begin 5, end -1, length 39
at java.lang.String.checkBoundsBeginEnd(String.java:3756) ~[?:?]
at java.lang.String.substring(String.java:1902) ~[?:?]
at
org.apache.jmeter.protocol.http.config.MultipartUrlConfig.parseArguments(MultipartUrlConfig.java:134)
~[ApacheJMeter_http.jar:5.4.2]
at
org.apache.jmeter.protocol.http.visualizers.RequestViewHTTP.setSamplerResult(RequestViewHTTP.java:228)
~[ApacheJMeter_http.jar:5.4.2]
at
org.apache.jmeter.visualizers.RequestPanel.setSamplerResult(RequestPanel.java:116)
~[ApacheJMeter_components.jar:5.4.2]
at
org.apache.jmeter.visualizers.SamplerResultTab.setupTabPane(SamplerResultTab.java:238)
~[ApacheJMeter_components.jar:5.4.2]
[...]
--
You are receiving this mail because:
You are the assignee for the bug.