Fork me on GitHub
#jackdaw
<
2022-08-03
>
Ben Davies14:08:54

Hey folks I’m looking to change my kafka streams application to use a custom partitioner on the https://kafka.apache.org/21/javadoc/org/apache/kafka/streams/kstream/KStream.html#to-java.lang.String-org.apache.kafka.streams.kstream.Produced- method of my topology. When I try and implement this using jackdaw I get this error

Uncaught exception, not in assertion
   error: clojure.lang.ArityException: Wrong number of args (3) passed to: jackdaw.streams/to
Currently the jackdaw.streams/to doesn’t accept a https://kafka.apache.org/23/javadoc/index.html?org/apache/kafka/streams/kstream/Produced.html interface. I’ve tried to do some java interop but because Jackdaw refactors the methods into functions I end up with the wrong args passed in this way as well. Is there a way of blending java interop with a jackdaw topology to get around this?

Alastair Hole16:08:16

Unfortunately the API docs seem to have been broken for a while, I’m not sure if there would be some answers there https://cljdoc.org/builds/60148

Alastair Hole16:08:30

This project seems rather quiet these days alas

Ben Davies16:08:18

I’m using an older version of Jackdaw 0.7.6 and have found the kstream* fn which does return the underlying object https://cljdoc.org/d/fundingcircle/jackdaw/0.7.6/api/jackdaw.streams#kstream*

Alastair Hole16:08:49

Ah good spot, that sounds promising