I am trying to send data to Kafka in an secured Kafka and I'm receiving this error message:
INFO [2016-01-18 17:41:17,878] kafka.producer.SyncProducer: Connected to broker:6667 for producing INFO [2016-01-18 17:41:17,887] kafka.producer.SyncProducer: Disconnecting from broker:6667 WARN [2016-01-18 17:41:17,899] kafka.client.ClientUtils$: Fetching topic metadata with correlation id 0 for topics [Set(abc_test)] from broker [id:0,broker,port:6667] failed ! java.io.EOFException: Received -1 when reading from channel, socket has likely been closed.
My Properties look like:
props.put("metadata.broker.list", conf.getBroker()); props.put("serializer.class", Encoder.class.getName()); props.put("security.protocol", "PLAINTEXTSASL"); props.put("sasl.kerberos.service.name", "kafka"); ProducerConfig pConf = new ProducerConfig(props); producer = new Producer<>(pConf);
Can anyone help ?
I'm startin with java -Djava.security.auth.login.config=/usr/hdp/current/kafka-broker/config/kafka_jaas.conf -jar application.
So the jaas.conf is already included