Skip to content

Commit

Permalink
docs: Use real example for EVENT_BUS_PRODUCER (#150)
Browse files Browse the repository at this point in the history
  • Loading branch information
timmc-edx authored Nov 29, 2022
1 parent 5e0908f commit af43d29
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion openedx_events/event_bus/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
- ``get_producer`` returns an ``EventBusProducer`` singleton that should be used for sending all events
to the Event Bus. The backing implementation is chosen via the Django setting ``EVENT_BUS_PRODUCER``.
See for example the Kafka implementation's ``KafkaEventProducer``, with the ``create_producer`` function
serving as the loader: https://github.com/openedx/event-bus-kafka/blob/main/edx_event_bus_kafka/internal/producer.py
"""

import warnings
Expand Down Expand Up @@ -97,7 +99,7 @@ def send(
# .. setting_description: String naming a callable (function or class) that can be called to create
# or retrieve an instance of EventBusProducer when ``openedx_events.event_bus.get_producer`` is
# called. The format of the string is a dotted path to an attribute in a module, e.g.
# ``some.module.path.EventBusImplementation``. This producer will be managed as a singleton
# ``edx_event_bus_kafka.create_producer``. This producer will be managed as a singleton
# by openedx_events. If setting is not supplied or the callable raises an exception or does not return
# an instance of EventBusProducer, calls to the producer will be ignored with a warning at startup.

Expand Down

0 comments on commit af43d29

Please sign in to comment.