You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: instrumentation/opentelemetry-instrumentation-kafka-python/src/opentelemetry/instrumentation/kafka/__init__.py
+31-3
Original file line number
Diff line number
Diff line change
@@ -38,6 +38,35 @@
38
38
for message in consumer:
39
39
# process message
40
40
41
+
The `_instrument` method accepts the following keyword args:
42
+
tracer_provider (TracerProvider) - an optional tracer provider
43
+
produce_hook (Callable) - a function with extra user-defined logic to be performed before sending the message
44
+
this function signature is:
45
+
def produce_hook(span: Span, args, kwargs)
46
+
consume_hook (Callable) - a function with extra user-defined logic to be performed after consuming a message
Copy file name to clipboardExpand all lines: instrumentation/opentelemetry-instrumentation-kafka-python/src/opentelemetry/instrumentation/kafka/utils.py
0 commit comments