@@ -1,5 +1,8 @@
1{-# LANGUAGE CPP #-}
1{-# LANGUAGE CPP #-}
3+-- | A thread pool manager.
4+-- The manager has responsibility to spawn and kill
3module Network.Wai.Handler.Warp.HTTP2.Manager (
6module Network.Wai.Handler.Warp.HTTP2.Manager (
@@ -26,8 +29,9 @@ data Command = Stop | Spawn | Replace ThreadId
26data Manager = Manager (TQueue Command) (IORef (IO ()))
29data Manager = Manager (TQueue Command) (IORef (IO ()))
28-- | Starting a thread pool manager.
31-- | Starting a thread pool manager.
32+-- Its action is initially set to 'return ()' and should be set
29−-- Its action is 'return ()' to allow the action can include
33+-- by 'setAction'. This allows that the action can include
30−-- this manager itself.
34+-- the manager itself.
31start :: IO Manager
35start :: IO Manager
33 tset <- newThreadSet
37 tset <- newThreadSet