You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Jeffrey Knight <je...@fastmail.com> on 2022/08/11 01:35:50 UTC

Confluent schema registry authentication with Kafka Component ?

Hello 


Can anyone point me in the right direction for how to configure auth settings for Confluent schema registry with the Kafka component ? 

 

I checked the code [1] and I see “schemaRegistryUrl” but no authentications option for it.

 

I suspect I need “schema.registry.basic.auth.user.info” and “basic.auth.credentials.source” settings when using the Camel Kafka component with the special Confluent schemaRegistryUrl setting [2]? 

 

This config works locally with no authentication but I am not seeing how to include authentication for confluent.cloud:

 

kafka:my.topic.name?schemaRegistryURL=http://localhost:9080

&keyDeserializer=org.apache.kafka.common.serialization.StringDeserializer

&valueDeserializer=io.confluent.kafka.serializers.KafkaAvroDeserializer

&specificAvroReader=true

&brokers=localhost:9092

&securityProtocol=SASL_SSL

&saslMechanism=PLAIN

&saslJaasConfig=RAW(org.apache.kafka.common.security.plain.PlainLoginModule required username="my-username" password="my-password/has slashes";)

 

-Jeff

 

[1] components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaConfiguration.java

[2] https://camel.apache.org/components/3.18.x/kafka-component.html#_component_option_schemaRegistryURL

 

See also: https://stackoverflow.com/questions/58835635/how-pass-basic-authentication-to-confluent-schema-registry

 


Re: Confluent schema registry authentication with Kafka Component ?

Posted by Jeffrey Knight <je...@fastmail.com>.
Answering my own question - use 'additionalProperties." -

kafka:my.topic.name?schemaRegistryURL=https://confluent.url.here
      &additionalProperties.basic.auth.credentials.source=USER_INFO
      &additionalProperties.basic.auth.user.info=[username]:[password]

[line breaks inserted for readability]


On 8/11/22, 02:36, "Jeffrey Knight" <je...@fastmail.com> wrote:

    Hello 


    Can anyone point me in the right direction for how to configure auth settings for Confluent schema registry with the Kafka component ? 



    I checked the code [1] and I see “schemaRegistryUrl” but no authentications option for it.



    I suspect I need “schema.registry.basic.auth.user.info” and “basic.auth.credentials.source” settings when using the Camel Kafka component with the special Confluent schemaRegistryUrl setting [2]? 



    This config works locally with no authentication but I am not seeing how to include authentication for confluent.cloud:



    kafka:my.topic.name?schemaRegistryURL=http://localhost:9080

    &keyDeserializer=org.apache.kafka.common.serialization.StringDeserializer

    &valueDeserializer=io.confluent.kafka.serializers.KafkaAvroDeserializer

    &specificAvroReader=true

    &brokers=localhost:9092

    &securityProtocol=SASL_SSL

    &saslMechanism=PLAIN

    &saslJaasConfig=RAW(org.apache.kafka.common.security.plain.PlainLoginModule required username="my-username" password="my-password/has slashes";)



    -Jeff



    [1] components/camel-kafka/src/main/java/org/apache/camel/component/kafka/KafkaConfiguration.java

    [2] https://camel.apache.org/components/3.18.x/kafka-component.html#_component_option_schemaRegistryURL



    See also: https://stackoverflow.com/questions/58835635/how-pass-basic-authentication-to-confluent-schema-registry