warp 1.3.1.2 → 1.3.2
raw patch · 5 files changed
+9/−6 lines, 5 filesdep ~simple-sendfile
Dependency ranges changed: simple-sendfile
Files
- Network/Wai/Handler/Warp.hs +1/−0
- Network/Wai/Handler/Warp/FdCache.hs +3/−3
- Network/Wai/Handler/Warp/Run.hs +1/−1
- Network/Wai/Handler/Warp/Settings.hs +2/−0
- warp.cabal +2/−2
Network/Wai/Handler/Warp.hs view
@@ -31,6 +31,7 @@ , settingsTimeout , settingsIntercept , settingsManager+ , settingsFdCacheDuration -- ** Data types , HostPreference (..) -- * Connection
Network/Wai/Handler/Warp/FdCache.hs view
@@ -76,8 +76,8 @@ ---------------------------------------------------------------- -initialize :: IO MutableFdCache-initialize = do+initialize :: Int -> IO MutableFdCache+initialize duration = do mfc <- newMutableFdCache void . forkIO $ loop mfc return mfc@@ -86,7 +86,7 @@ old <- swapWithNew mfc new <- pruneWith old prune update mfc (merge new)- threadDelay 10000000 -- FIXME+ threadDelay duration loop mfc prune :: t -> Some FdEntry -> IO [(t, Some FdEntry)]
Network/Wai/Handler/Warp/Run.hs view
@@ -126,7 +126,7 @@ tm <- maybe (T.initialize $ settingsTimeout set * 1000000) return $ settingsManager set #if !WINDOWS- fc <- F.initialize+ fc <- F.initialize (settingsFdCacheDuration set * 1000000) #endif mask $ \restore -> forever $ do allowInterrupt
Network/Wai/Handler/Warp/Settings.hs view
@@ -25,6 +25,7 @@ , settingsTimeout :: Int -- ^ Timeout value in seconds. Default value: 30 , settingsIntercept :: Request -> Maybe (Source (ResourceT IO) S.ByteString -> Connection -> ResourceT IO ()) , settingsManager :: Maybe Manager -- ^ Use an existing timeout manager instead of spawning a new one. If used, 'settingsTimeout' is ignored. Default is 'Nothing'+ , settingsFdCacheDuration :: Int -- ^ Cache duratoin time of file descriptors in seconds. Default value: 10 } -- | The default settings for the Warp server. See the individual settings for@@ -44,6 +45,7 @@ , settingsTimeout = 30 , settingsIntercept = const Nothing , settingsManager = Nothing+ , settingsFdCacheDuration = 10 } where go :: InvalidRequest -> IO ()
warp.cabal view
@@ -1,5 +1,5 @@ Name: warp-Version: 1.3.1.2+Version: 1.3.2 Synopsis: A fast, light-weight web server for WAI applications. License: MIT License-file: LICENSE@@ -26,7 +26,7 @@ , http-types >= 0.7 && < 0.8 , lifted-base >= 0.1 && < 0.2 , network-conduit >= 0.5 && < 0.6- , simple-sendfile >= 0.2.4 && < 0.3+ , simple-sendfile >= 0.2.7 && < 0.3 , transformers >= 0.2.2 && < 0.4 , unix-compat >= 0.2 , void