(consumer! {:keys [topic properties duration] :or {duration 100}})
Receives a map of a topic and the java properties. Returns a channel, which will be populated with individual messages from the kafka topic.
Receives a map of a topic and the java properties. Returns a channel, which will be populated with individual messages from the kafka topic.
(consumer-batch! {:keys [topic properties duration] :or {duration 100}})
Receives a map of a topic and the java properties. Returns a channel, which will be populated with a list of messages from the kafka topic. Each list of messages corresponds to a iteration of the consumer poll.
Receives a map of a topic and the java properties. Returns a channel, which will be populated with a list of messages from the kafka topic. Each list of messages corresponds to a iteration of the consumer poll.
(producer! {:keys [topic properties flush?] :or {flush? true}})
Receives a map of a topic and the java properties. Returns a channel that will be consumed and sent each individual message to kafka in a different thread.
Receives a map of a topic and the java properties. Returns a channel that will be consumed and sent each individual message to kafka in a different thread.
(worker! channel f)
(worker! channel f extra)
Execute a function f each time a message is received at the channel.
Checks if a exception is passed in a channel, if it is f will not be applied and the exception will be logged.
An optional list of extra arguments can be passed to worker!
and will be passed to f
as the second argument.
Execute a function f each time a message is received at the channel. Checks if a exception is passed in a channel, if it is f will not be applied and the exception will be logged. An optional list of extra arguments can be passed to `worker!` and will be passed to `f` as the second argument.
(worker-batch! channel n f)
(worker-batch! channel n f extra)
Execute a function f
for every n
messages received at the channel.
Checks if a exception is passed in a channel, if it is f will not be applied and the exception will be logged.
An optional extra argument can be passed to worker-batch!
and will be passed to f
as the second argument.
Execute a function `f` for every `n` messages received at the channel. Checks if a exception is passed in a channel, if it is f will not be applied and the exception will be logged. An optional extra argument can be passed to `worker-batch!` and will be passed to `f` as the second argument.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close