Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data ShutdownLatch
- newShutdownLatch :: IO ShutdownLatch
- waitForShutdown :: ShutdownLatch -> IO ()
- shutdownGracefully :: ShutdownLatch -> IO ()
- shuttingDown :: ShutdownLatch -> IO Bool
Documentation
data ShutdownLatch Source #
A latch for the graceful shutdown of a server process.
waitForShutdown :: ShutdownLatch -> IO () Source #
Block the current thread, waiting on the latch.
shutdownGracefully :: ShutdownLatch -> IO () Source #
Initiate a graceful shutdown of the server associated with the provided latch.
shuttingDown :: ShutdownLatch -> IO Bool Source #
Returns True if the latch is set for shutdown and vice-versa