From e3ea04d8e71370032da56ad9ea66dcb82d257812 Mon Sep 17 00:00:00 2001 From: Tom Smeding Date: Fri, 8 May 2026 20:59:08 +0100 Subject: Instrument handler blocks --- mini-http-server/Network/HTTP/Server/Mini.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'mini-http-server/Network/HTTP/Server/Mini.hs') diff --git a/mini-http-server/Network/HTTP/Server/Mini.hs b/mini-http-server/Network/HTTP/Server/Mini.hs index 266e958..fb982d7 100644 --- a/mini-http-server/Network/HTTP/Server/Mini.hs +++ b/mini-http-server/Network/HTTP/Server/Mini.hs @@ -13,6 +13,7 @@ import Network.Socket import Network.Socket.ByteString import Network.HTTP.Server.Mini.Internal.Parser +import Network.HTTP.Server.Mini.Internal.Instrument import Network.HTTP.Server.Mini.Printer import Network.HTTP.Server.Mini.Types @@ -72,5 +73,5 @@ handleConnection settings conn handler = readRequest (setMaxRequestSize settings) (recv conn) >>= \case Nothing -> return () Just req -> do - resp <- handler req - sendResponse conn resp + resp <- instrument "handler" $ handler req + instrument "sendResponse" $ sendResponse conn resp -- cgit v1.3.1