diff options
author | 2018-09-17 10:19:14 -0400 | |
---|---|---|
committer | 2018-09-17 10:19:58 -0400 | |
commit | 961111d365e34163334fb3dbf34222ac354d8a3c (patch) | |
tree | a2a96ea898d4f4ad7477068dc25888af069c4dbf /src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java | |
parent | fbee998c8115045344cb1d9e8e9edded5f19ac87 (diff) |
Changes for Kafka AAF integration
Issue-ID: DMAAP-772
Change-Id: I60e07746c48967500f744f3fe9632d55197277bb
Signed-off-by: sunil unnava <sunil.unnava@att.com>
Diffstat (limited to 'src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java')
-rw-r--r-- | src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java b/src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java index 4bef985..c89a3b2 100644 --- a/src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java +++ b/src/main/java/com/att/dmf/mr/beans/DMaaPKafkaMetaBroker.java @@ -82,9 +82,10 @@ public class DMaaPKafkaMetaBroker implements Broker1 { fkafkaBrokers = "localhost:9092"; } - - props.put(AdminClientConfig.BOOTSTRAP_SERVERS_CONFIG, fkafkaBrokers ); + props.put("sasl.jaas.config", "org.apache.kafka.common.security.plain.PlainLoginModule required username='admin' password='admin_secret';"); + props.put(AdminClientConfig.SECURITY_PROTOCOL_CONFIG, "SASL_PLAINTEXT"); + props.put("sasl.mechanism", "PLAIN"); fKafkaAdminClient=AdminClient.create ( props ); @@ -118,7 +119,9 @@ public class DMaaPKafkaMetaBroker implements Broker1 { } - + props.put("sasl.jaas.config", "org.apache.kafka.common.security.plain.PlainLoginModule required username='admin' password='admin_secret';"); + props.put(AdminClientConfig.SECURITY_PROTOCOL_CONFIG, "SASL_PLAINTEXT"); + props.put("sasl.mechanism", "PLAIN"); props.put(AdminClientConfig.BOOTSTRAP_SERVERS_CONFIG, fkafkaBrokers ); fKafkaAdminClient=AdminClient.create ( props ); |