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
I would like to add tracing to my bot, so I was looking at setting up middleware to add tracing to each request. It does however look like middleware only can be triggered for incoming requests and not for the outgoing responses.
Would it be possible to let middleware's hook into the response action? That way, a trace can be started in the middleware and attached to the context of the request, and then finalised when the response is being sent after the event has been handled.
Category (place an x in each of the [ ])
slack_bolt.App and/or its core components
slack_bolt.async_app.AsyncApp and/or its core components
As you mentioned, a global middleware is not a right solution for this. A suggested way to do this is to have your own adapter. With your own adapter, you can hook the timings of the BotRequest construction from raw HTTP requests and the BoltResponse conversion to a valid HTTP/Socket Mode response.
Thank you! That's really helpful. I'll take a look at this next week. I'll close this ticket and get back if I've got further questions. Have a nice weekend.
I would like to add tracing to my bot, so I was looking at setting up middleware to add tracing to each request. It does however look like middleware only can be triggered for incoming requests and not for the outgoing responses.
Would it be possible to let middleware's hook into the response action? That way, a trace can be started in the middleware and attached to the context of the request, and then finalised when the response is being sent after the event has been handled.
Category (place an
x
in each of the[ ]
)Requirements
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.
The text was updated successfully, but these errors were encountered: