flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From prateekarora <prateek.arora...@gmail.com>
Subject Re: Getting java.lang.Exception when try to fetch data from Kafka
Date Mon, 25 Apr 2016 20:16:40 GMT
Hi

I have java program to send data into kafka topic. below is code for this :

private Producer<String, byte[]> producer = null

Serializer<String> keySerializer = new StringSerializer();
Serializer<byte[]> valueSerializer = new ByteArraySerializer();
producer = new KafkaProducer<String, byte[]>(props, keySerializer,
valueSerializer);

ProducerRecord<String, byte[]> imageRecord;
imageRecord = new ProducerRecord<String, byte[]>(streamInfo.topic,
                        Integer.toString(messageKey), imageData);

producer.send(imageRecord);


then trying to fetch data in Apache flink .

Regards
Prateek




--
View this message in context: http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/Getting-java-lang-Exception-when-try-to-fetch-data-from-Kafka-tp6365p6418.html
Sent from the Apache Flink User Mailing List archive. mailing list archive at Nabble.com.

Mime
View raw message