Skip to content

Commit 90d11df

Browse files
committed
add documentation for stats_cb
1 parent eb31ace commit 90d11df

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/index.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ The Python bindings also provide some additional configuration properties:
8181
* ``error_cb(kafka.KafkaError)``: Callback for generic/global error events. This callback is served by
8282
poll().
8383

84+
* ``stats_cb(json_str)``: Callback for statistics data. This callback is triggered by poll() every ``statistics.interval.ms`` (needs to be configured separately). Function argument ``json_str`` is a str instance of a JSON document containing statistics data.
85+
8486
* ``on_delivery(kafka.KafkaError, kafka.Message)`` (**Producer**): value is a Python function reference
8587
that is called once for each produced message to indicate the final
8688
delivery result (success or failure).

0 commit comments

Comments
 (0)