It has to be possible to run arbitrary code before/after a swoole task is executed.
Currently, the use case is to be able to gracefully recover from a closed DB connection, the same way it's done for web workers using the CloseDbConnectionMiddleware, which closes the connection after the execution and reopens it on next request.
It has to be possible to run arbitrary code before/after a swoole task is executed.
Currently, the use case is to be able to gracefully recover from a closed DB connection, the same way it's done for web workers using the CloseDbConnectionMiddleware, which closes the connection after the execution and reopens it on next request.