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 ability to connect to specific kafka cluster node hostname #633

Merged
merged 5 commits into from
Dec 12, 2023
Merged

Support ability to connect to specific kafka cluster node hostname #633

merged 5 commits into from
Dec 12, 2023

Conversation

akrambek
Copy link
Contributor

Description

Support ability to connect to specific kafka cluster node hostname

jfallows
jfallows previously approved these changes Dec 12, 2023
jfallows
jfallows previously approved these changes Dec 12, 2023
@@ -1280,6 +1280,7 @@ private void doConnectionBegin(
.destination(host)
.sourcePort(0)
.destinationPort(port)))
.infos(i -> i.item(ii -> ii.authority(host)))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be coming from ProxyBeginEx info authority, not host, and address key for shared connections should include authority in addition to host and port, agree?

Otherwise, two streams differing only by authority would be treated as equal, even though their TLS handshakes would have a different sni.

@@ -79,7 +78,7 @@ public final class KafkaClientConnectionPool extends KafkaClientSaslHandshaker
private static final int SIGNAL_STREAM_WINDOW = 0x80000006;
private static final int SIGNAL_CONNECTION_CLEANUP = 0x80000007;
private static final int SIGNAL_NEXT_REQUEST = 0x80000008;
private static final String CLUSTER = "";
private static final StringBuilder CLUSTER = new StringBuilder("");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be non-static as it is mutable and static is shared across cores.

@jfallows jfallows merged commit ec1db3b into aklivity:develop Dec 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants