Skip to content

Instantly share code, notes, and snippets.

View algas's full-sized avatar

Masahiro Yamauchi algas

View GitHub Profile
module Web.Scotty.Async
where
import Control.Concurrent (ThreadId, forkIO, newEmptyMVar, putMVar, takeMVar)
import Control.Concurrent.Async (async, Async(..))
import Data.Default (def)
import Network.Wai.Handler.Warp (Port, defaultSettings, setBeforeMainLoop,
setPort)
import Web.Scotty (Options(..), ScottyM, scottyOpts)