Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add documentation for stats_cb
  • Loading branch information
hqin committed Nov 2, 2016
commit 90d11df2525fc528dc4aa7a65f72c93b784fa60f
2 changes: 2 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,8 @@ The Python bindings also provide some additional configuration properties:
* ``error_cb(kafka.KafkaError)``: Callback for generic/global error events. This callback is served by
poll().

* ``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.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

docs are good, but split up the lines at about 80 columns so it is readable in the terminal too.


* ``on_delivery(kafka.KafkaError, kafka.Message)`` (**Producer**): value is a Python function reference
that is called once for each produced message to indicate the final
delivery result (success or failure).
Expand Down