v0.0.5 Lifespan / Lifecycle events #77
                  
                    
                      cirospaciari
                    
                  
                
                  announced in
                Announcements
              
            Replies: 0 comments
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
-
What is changed in socketify:
res.sendandres.cork_sendLifespan / Lifecycle events
Now you can use socketify start and shutdown events to create/clean thread pools, connections pools, etc when the application starts or shutdown itself.
If any exception occurs in the start event the application will continue and start normally,
if you want to fail a start you need to catch the exception and use
sys.exit(1)to shut down prematurely.Both
app.on_startandapp.on_shutdowncan be sync or async.Work in progress for v0.1.0:
This discussion was created from the release v0.0.5 Lifespan / Lifecycle events.
Beta Was this translation helpful? Give feedback.
All reactions