Replies: 2 comments
-
|
Hey, its been a long time since you asked this, but did you by chance resolve this issue? I'm seeing this exact problem in 2.19. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
linkerd probably doesn't handle kafka protocol's idiosyncracies, see https://linkerd.io/2-edge/features/protocol-detection/#protocols-that-may-require-configuration for latest. If it helps: I am using strimzi's TLS client certs that strimzi's operator provisions and rotates instead of meshing, so you would need to provide strimzi's trust store and client certs to your application, of course. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, everyone!
We are currently experimenting with Linkerd service mesh. One of the scenarios that we are testing is the ability of a Java SpringBoot application (single pod) to talk to a Kafka cluster (single broker node) via Linkerd: that would allow us to encrypt Kafka traffic without the hassle of managing certificates, etc. Our setup is as follows:
We run a self-hosted Rancher RKE2 Kubernetes cluster (version v1.23.14+rke2r1) on a bunch of VMs in a private cloud (Oracle Linux 8 is the underlying OS).
Java SpringBoot application runs in
devnamespace of the cluster. It manages two containers: one for the application, another - for Hashicorp Vault agent (alongside with Vault Agent init container):Strimzi-operated Kafka cluster runs in
strimzinamespace of the same K8S cluster (operator version 0.32.0):It is worth noting that
kafka-cluster-kafka-0pod along with the other pods is not managed by a StatefulSet. Instead, it is managed by a StrimziPodSet:The Kafka broker exposes port 9092 (among others) as a plain internal port (no TLS / authentication enabled) via a number of services, both ClusterIP and Headless:
The application is configured to connect to the cluster via a ConfigMap setting an environment variable:
Without Linkerd, this setup works fine: the application is able to connect broker node and interact with its topics. Similarly, if we have Linkerd injected on either side of this setup, the application is able to connect without issues.
For Kafka, we inject Linkerd via the annotations of Kafka custom resource:
Injection of Linkerd to the application pod is done via the
kubectl -n dev get deploy app | linkerd inject - | kubectl apply -f -command pipe.Once we have Linkerd injected on both sides of the setup, the application is no longer able to connect to Kafka, as the connection times out. In application logs, we see:
In logs of the proxy on the application side, there are records as follows:
In the debug logs of the Kafka Pod, there are no traces of the connection attempts from this pod.
The timeout of
1sis coming from the proxy: we experimented with increasing it to up to 1m via annotations, but this didn't make any difference.So far we have tried to use other services' DNS names and even the IP address of the Kafka broker Pod in
SPRING_KAFKA_BOOTSTRAP_SERVERSenvironemnt variable, but non fixed the issue.Any help would be much appreciated.
Beta Was this translation helpful? Give feedback.
All reactions