asgi 'lifespan.shutdown'
Bot-Publishing Inc.
info at botpublishing.com
Mon Dec 28 17:04:35 UTC 2020
Hello,
I am trying to determine the best way to introduce a resource clean up
logic into a python module that is called using ASGI protocol.
I am successfully catching the *'lifespan.startup' *event from within my
async def application(scope, receive, send*) *implementation.
Unfortunately, I do not see the *'lifespan.shutdown' *event when the
process is unloaded.
My config file includes:
"processes": {
"max": 3,
"spare": 1,
"idle_timeout": 10
},
I was under the assumption that the above config will force the idle
processes to shut down resulting in the *'lifespan.shutdown' *event .
Would appreciate any assistance.
gen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/unit/attachments/20201228/e2c65cf5/attachment.htm>
More information about the unit
mailing list