-
Notifications
You must be signed in to change notification settings - Fork 100
Closed
Description
I've instrumented my indexing code with openllmetry; when submitting batches on the ThreadPoolExecutor the context (used by otel to propagate trace) isn't being passed:
self.__executor.submit( |
following is suggested fix:
# do not block the thread - the results are written to a central (locked) list and we want to have multiple concurrent batch-requests
ctx = contextvars.copy_context()
self.__executor.submit(
ctx.run,
functools.partial(self.__send_batch, objs, refs, readd_rate_limit=isinstance(self.__batching_mode, _RateLimitedBatching)),
)
Metadata
Metadata
Assignees
Labels
No labels