ScorpioBroker
ScorpioBroker copied to clipboard
Connecting to Kafka
I am trying to set the following parameters for kafka:
bootstrap.servers=pkc-e8mp5.eu-west-1.aws.confluent.cloud:9092
ssl.endpoint.identification.algorithm=https
security.protocol=SASL_SSL
sasl.mechanism=PLAIN
sasl.jaas.config=org.apache.kafka.common.security.plain.PlainLoginModule required username="{{ CLUSTER_API_KEY }}" password="{{ CLUSTER_API_SECRET }}";
but I am not having much luck. I am trying to do something like below - for running in docker.
If you like, I can let you have my username and key if you need to test 😃
Hi, i think i got the problem. We are using also the spring cloud kafka binders which are using another config option. We haven't really yet played with this scenarios so this isn't properly documented. Sorry about that. If you add the --spring.cloud.stream.kafka.binder. options should do the trick --spring.cloud.stream.kafka.binder.brokers is the only one we are setting manually please find the security settings for this here https://cloud.spring.io/spring-cloud-stream-binder-kafka/spring-cloud-stream-binder-kafka.html#_example_security_configuration
BR
I am now able to connect to Kafka, but only when I change the application.yml file directly. The setup below actually works, and connects to a cloud hosted Kafka instance. Could you perhaps please advise me how to do the same configuration via. parameters to the Docker container ? It seems to be slightly more complicated to pass the security information to the docker container, so perhaps you have a solution. @ScorpioBroker

I was trying to use the AIO-Deployment with an external Kafka (MKS in my case). Setting the environment variable BOOTSTRAP_SERVERS
for the container was all I had to do in my case. This will override the internal bootstrap.servers
entry.
@Glagnar Do you know if these same parameters can be used with the Scorpio Broker to authenticate with OAuth Bearer tokens?