Thanks, Matthias, I had not considered this. I will take a look at the streams use case.
Thanks On Wed, May 17, 2017 at 4:58 PM, Matthias J. Sax <matth...@confluent.io> wrote: > Did you try out Kafka Streams API instead of wrapping the consumer? It > does support Lambdas already: > > https://github.com/confluentinc/examples/blob/3. > 2.x/kafka-streams/src/main/java/io/confluent/examples/streams/ > MapFunctionLambdaExample.java#L126 > > Full docs: http://docs.confluent.io/current/streams/index.html > > > -Matthias > > On 5/17/17 1:45 PM, Robert Quinlivan wrote: > > Hello, > > > > I've been looking at writing a Java 8 streams API wrapper for the Kafka > > consumer. Since this seems like a common use case I was wondering if > > someone in the user community had already begun a project like this. > > > > My goal is to be able to get back a Stream<ConsumerRecord<K, V>> wrapping > > the results of #poll() which can then be passed into a map/filter > pipeline. > > I am using an underlying blocking queue data structure to buffer in > memory > > and using Stream.generate() to pull records. Any recommendations on a > best > > approach here? > > > > Thanks > > > > -- Robert Quinlivan Software Engineer, Signal