jmxOptions and credentials to the endpoint #4442
-
Hi guys, We pushed the following configuration to our strimzi cluster:
Not sure if I misunderstood the docs, but i was expecting for the http call to the endpoint to ask for credentials as described in the documentation here:
So calls using localhost, or even from another the pod/namespace using the headless service, they work without asking for any user / password. It's not a big issue for us as the ports are not going to exposed externally, only prometheus service discovery will connect to those ports, but just to understand if it's really having any effect in the endpoint. The secret for the JMX option was anyway created, with the user / password in it. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
AFAIK JMX is not based on HTTP. The The metrics endpoint you are accessing there with the |
Beta Was this translation helpful? Give feedback.
-
@scholzj I have been exploring the same issue. I can go inside kafka-exporter pod and issue a curl command here it suggests that it is possible to access the metrics both http://localhost:9999/metrics and via java jmx . How can we reach at the kafka broker jmx export endpoint via curl inside the kafka container? Could it that no http port is mapped in the strimzi config and thus simply http://localhost:9999/metrics does not work. |
Beta Was this translation helpful? Give feedback.
AFAIK JMX is not based on HTTP. The
jmxOptions
configure the access to the broker using the Java JMX protocol and that is where the password should be needed.The metrics endpoint you are accessing there with the
curl http://localhost:9404/metrics
is the JMX Exporter whihc takes the JMX metrics and exports them in Prometheus format as HTTP. That has no password protection. This is controlled by themetrics
/metricsConfig
fields.