Bug 64010 - HttpCLient4 adds default header that can not be easly removed. (Java does not)
Summary: HttpCLient4 adds default header that can not be easly removed. (Java does not)
Status: NEW
Alias: None
Product: JMeter
Classification: Unclassified
Component: HTTP (show other bugs)
Version: 5.2.1
Hardware: PC
: P2 normal (vote)
Target Milestone: JMETER_5.2
Assignee: JMeter issues mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-12-17 11:22 UTC by szuther
Modified: 2019-12-17 11:22 UTC (History)
0 users



Attachments
Test + pics (55.15 KB, application/x-zip-compressed)
2019-12-17 11:22 UTC, szuther
Details

Note You need to log in before you can comment on or make changes to this bug.
Description szuther 2019-12-17 11:22:22 UTC
Created attachment 36919 [details]
Test + pics

httpClient4 adds

"Content-Type: application/x-www-form-urlencoded; charset=UTF-8"

(and other Header, see attached pics) for POST requests even if i don’t have specified any Header for that request,

Content-Type is unnecessary for a post without a Body.

The Server don’t except "application/x-www-form-urlencoded" as Content-Type and the Request will fail.

The Server would accept a request without Content-Type header.

The Java implementation does that not.
Its not good to have these completely different behaviour and there is no (easy?) way to send a POST request without the Content-Type Header with httpClient4.


In the attachment is the simple POST test without defined header and images of the sent request headers with java and httpclient4 implementation