Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ovverride host header in netty #5217

Closed
gollapa opened this issue Dec 15, 2022 · 2 comments
Closed

ovverride host header in netty #5217

gollapa opened this issue Dec 15, 2022 · 2 comments
Assignees
Labels

Comments

@gollapa
Copy link

gollapa commented Dec 15, 2022

When we make the oubound rest call we have a requirement to use the NAT IP address instead of the actual host name. When making such calls we need to pass the host header for the call to succeed. But currently in netty there is no provision to include the host header. Netty adds a host header which it derives from the Uri. If we explictly add a host header in the request ,netty adds one more host header which results in a bad request.

We need a way to override the hostheader in the request.

code from NettyConnector which sets the header:
nettyRequest.headers().add(HttpHeaderNames.HOST, jerseyRequest.getUri().getHost());

we are using jersey with netty connector version 2.37

@jansupol jansupol added the netty label Dec 20, 2022
@gollapa
Copy link
Author

gollapa commented Dec 29, 2022

any update?

@jansupol jansupol self-assigned this Jan 20, 2023
@jansupol
Copy link
Contributor

Fixed by #5241.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants