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

Support SocketAddress for proxies #3242

Closed
AlexProgrammerDE opened this issue May 14, 2024 · 2 comments · Fixed by #3243
Closed

Support SocketAddress for proxies #3242

AlexProgrammerDE opened this issue May 14, 2024 · 2 comments · Fixed by #3243
Assignees
Labels
type/enhancement A general enhancement
Milestone

Comments

@AlexProgrammerDE
Copy link
Contributor

AlexProgrammerDE commented May 14, 2024

Currently proxies are required to be InetSocketAddress, but netty allows any SocketAddress to be used as a proxy.
This can be seen in in the ProxyProvider class:

public final Builder address(Supplier<? extends InetSocketAddress> addressSupplier) {

Motivation

I'm interested in using UnixDomainSocket for proxies instead of InetSocketAddress.

Desired solution

Extend the functionality of the proxy provider class to allow passing a SocketAddress instead of a InetSocketAddress to a proxy.
I've made a rough example how that could be made in a fork of mine: AlexProgrammerDE@a76c01d
It tries to keep backwards support until the next major release is made.
I'd recommend the maintainers use my commit as a reference.

Considered alternatives

Support UnixDomainSocket instead, but it's probably easier to just support SocketAddress directly to allow other future implementations of that class.

@AlexProgrammerDE AlexProgrammerDE added status/need-triage A new issue that still need to be evaluated as a whole type/enhancement A general enhancement labels May 14, 2024
@violetagg
Copy link
Member

violetagg commented May 14, 2024

@AlexProgrammerDE Are you interested in providing a PR? Which Reactor Netty version should enable this feature (1.1.x or 1.2.x)?

@violetagg violetagg removed the status/need-triage A new issue that still need to be evaluated as a whole label May 14, 2024
AlexProgrammerDE added a commit to AlexProgrammerDE/reactor-netty that referenced this issue May 14, 2024
This commit adds new socketAddress methods and tries to keep backwards compat for users using the old address methods, which are deprecated. I'd recommend removing socketAddress and renaming it back to address on the next major release.

Fixes reactor#3242
@AlexProgrammerDE
Copy link
Contributor Author

Opened at #3243
I think 1.2.x works.

@violetagg violetagg added this to the 1.2.0-M3 milestone May 14, 2024
violetagg pushed a commit that referenced this issue May 15, 2024
…3243)

This commit adds new socketAddress methods and tries to keep backwards compat for users using the old address methods, which are deprecated. I'd recommend removing socketAddress and renaming it back to address on the next major release.

Fixes #3242
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement A general enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants