Liking cljdoc? Tell your friends :D

felice.producer


->recordclj

(->record topic value)
(->record topic key value)

creates a record map given a topic, a value and an optional key

creates a record map given a topic, a value and an optional key
sourceraw docstring

close!clj

(close! producer)
(close! producer timeout)

This method waits up to timeout ms for the producer to complete the sending of all incomplete requests.

If the producer is unable to complete all requests before the timeout expires, this method will fail any unsent and unacknowledged records immediately.

Calling close with no timeout is equivalent to close(Long.MAX_VALUE, TimeUnit.MILLISECONDS)

This method waits up to timeout ms for the producer to complete the
sending of all incomplete requests.

If the producer is unable to complete all requests before the timeout
expires, this method will fail any unsent and unacknowledged records immediately.

Calling close with no timeout is equivalent to close(Long.MAX_VALUE, TimeUnit.MILLISECONDS)
sourceraw docstring

CONF-COERCERSclj

source

flush!clj

(flush! producer)

Invoking this method makes all buffered records immediately available to send (even if linger.ms is greater than 0) and blocks on the completion of the requests associated with these records.

Invoking this method makes all buffered records immediately available
to send (even if linger.ms is greater than 0) and blocks on the
completion of the requests associated with these records.
sourceraw docstring

metricsclj

(metrics producer)

Get the full set of internal metrics maintained by the producer.

Get the full set of internal metrics maintained by the producer.
sourceraw docstring

partitions-forclj

(partitions-for producer topic)

Get the partition metadata for the given topic.

Get the partition metadata for the given topic.
sourceraw docstring

producerclj

(producer conf)
(producer conf key-serializer value-serializer)

Create a producer

conf is a map {:keyword value} See https://kafka.apache.org/documentation/#producerconfigs for all possibilities

key and value serializer can be one of keys defined in felice.serializer namespace with the 1 argument arity, :key.serializer and :value.serializer must be provided in conf

Create a producer

`conf` is a map {:keyword value}
See https://kafka.apache.org/documentation/#producerconfigs for all possibilities

key and value serializer can be one of keys defined in `felice.serializer` namespace
with the 1 argument arity, :key.serializer and :value.serializer must be provided in conf
sourceraw docstring

send!clj

(send! producer record-map)
(send! producer topic value)
(send! producer topic key value)

asynchronously send a record

asynchronously send a record
sourceraw docstring

send!!clj

(send!! producer record-map)
(send!! producer topic value)
(send!! producer topic key value)

Synchronously send a record - wait until acknowledged

Synchronously send a record - wait until acknowledged
sourceraw docstring

send-with-callback!clj

(send-with-callback! producer record-map cb)
(send-with-callback! producer topic value cb)
(send-with-callback! producer topic key value cb)

Asynchronously send a record triggering the given callback when the send has been acknowledged. Note that callbacks will generally execute in the I/O thread of the producer and so should be reasonably fast or they will delay the sending of messages from other threads.

If you want to execute blocking or computationally expensive callbacks it is recommended to use your own Executor in the callback body to parallelize processing.

Asynchronously send a record triggering the given callback when the send has
been acknowledged.
Note that callbacks will generally execute in the I/O thread of the producer
and so should be reasonably fast or they will delay the sending of messages
from other threads.

If you want to execute blocking or computationally expensive callbacks it
is recommended to use your own Executor in the callback body to parallelize
processing.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close