Hoogle Search

Within LTS Haskell 24.67 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. setOnException :: (Maybe Request -> SomeException -> IO ()) -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    What to do with exceptions thrown by either the application or server. Default: defaultOnException Since 2.1.0

  2. setOnExceptionResponse :: (SomeException -> Response) -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    A function to create a Response when an exception occurs. Default: defaultOnExceptionResponse Note that an application can handle its own exceptions without interfering with Warp:

    myApp :: Application
    myApp request respond = innerApp `catch` onError
    where
    onError = respond . response500 request
    
    response500 :: Request -> SomeException -> Response
    response500 req someEx = responseLBS status500 -- ...
    
    Since 2.1.0

  3. setOnOpen :: (SockAddr -> IO Bool) -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    What to do when a connection is opened. When False is returned, the connection is closed immediately. Otherwise, the connection is going on. Default: always returns True. Since 2.1.0

  4. setPort :: Port -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    Port to listen on. Default value: 3000 Since 2.1.0

  5. setProxyProtocolNone :: Settings -> Settings

    warp Network.Wai.Handler.Warp

    Do not use the PROXY protocol. Since 3.0.5

  6. setProxyProtocolOptional :: Settings -> Settings

    warp Network.Wai.Handler.Warp

    Use the PROXY header if it exists, but also accept connections without the header. See setProxyProtocolRequired. WARNING: This is contrary to the PROXY protocol specification and using it can indicate a security problem with your architecture if the web server is directly accessible to the public, since it would allow easy IP address spoofing. However, it can be useful in some cases, such as if a load balancer health check uses regular HTTP without the PROXY header, but proxied connections do include the PROXY header. Since 3.0.5

  7. setProxyProtocolRequired :: Settings -> Settings

    warp Network.Wai.Handler.Warp

    Require PROXY header. This is for cases where a "dumb" TCP/SSL proxy is being used, which cannot add an X-Forwarded-For HTTP header field but has enabled support for the PROXY protocol. See http://www.haproxy.org/download/1.5/doc/proxy-protocol.txt and http://docs.aws.amazon.com/ElasticLoadBalancing/latest/DeveloperGuide/TerminologyandKeyConcepts.html#proxy-protocol. Only the human-readable header format (version 1) is supported. The binary header format (version 2) is not supported. Since 3.0.5

  8. setServerName :: ByteString -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    Default server name to be sent as the "Server:" header if an application does not set one. If an empty string is set, the "Server:" header is not sent. This is true even if an application set one. Since 3.0.2

  9. setServerPushLogger :: (Request -> ByteString -> Integer -> IO ()) -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    Setting a log function for HTTP/2 server push. Since: 3.2.7

  10. setSlowlorisSize :: Int -> Settings -> Settings

    warp Network.Wai.Handler.Warp

    Size in bytes read to prevent Slowloris attacks. Default value: 2048 Since 3.1.2

Page 167 of many | Previous | Next