Skip to content

Default Client does not include Content-Length header for POST with Empty Body #1229

@brennerm

Description

@brennerm

We are using Feign 10.7.4 to execute a POST request with an empty body. In this case Feign does not add a Content-Length header to the request. According to the HTTP specification this is fine but some proxies, in our case Azure API Management, do not accept POST request with no Content-Length header. Would it be possible to add a Content-Length: 0 header to PATCH, POST and PUT requests with an empty body?

Further context:

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugUnexpected or incorrect behaviorhelp wantedIssues we need help with tackling

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions