Bug 49949

Summary: Can't add fields to Multipart body headers
Product: JMeter Reporter: Romuald <romuald.balghagi>
Component: HTTPAssignee: JMeter issues mailing list <issues>
Status: NEW ---    
Severity: enhancement    
Priority: P2    
Version: 2.3.4   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
Attachments: Screenshot of a HTTP Request dump with MS NETMON 3.3

Description Romuald 2010-09-17 07:37:59 UTC
Created attachment 26041 [details]
Screenshot of a HTTP Request dump with MS NETMON 3.3

When using the HTTPClient tool, we can attach a file or many and name it but in some occasions we would be interested in adding header aside from the usual Content-Disposition and Content-Type, Content-Transfer-Encoding.

Some applications like SAP with their Archivelink HTTP interface are adding fields there (X-compId as an example).

Therefore for such applications it is not possible to simulate a file upload with a POST request as the backend webserver is not able to manage it (doesn't receive the missing header field).

In the attached screenshot I have highlighted in yellow the piece that I would like to configure the same way we can do with the HeaderManager for example.

Hope I didn't use bugzilla by mistake as I didn't find another location to post this enhancement request. If it is the case I am more than happy to post it at the right place.

Thanks.
Comment 1 Sebb 2010-12-02 18:32:51 UTC
As a work-round, you could create a file containing the complete POST body, and upload that, see:

http://jakarta.apache.org/jmeter/usermanual/component_reference.html#HTTP_Request

"If it is a POST or PUT request and there is a single file whose 'name' attribute (below) is omitted, then the file is sent as the entire body of the request, i.e. no wrappers are added. This allows arbitrary bodies to be sent."