Python: Breadcrumbs and Context in an event-loop (like Twisted)


#1

Our web-server is built with twisted/klein (built on top of twisted.web).

How can we use breadcrumbs and context, locally to a request in the Twisted event-loop, so that when multiple requests are handled in parallel, the breadcrumbs emitted in each request do not get mixed up together ? And how to attach the context to a request, so that each request have its own context ?