Skip to content

Commit

Permalink
Merge pull request #107 from creichert/master
Browse files Browse the repository at this point in the history
Change default connection time bound calculation from 5s to 5min.
  • Loading branch information
creichert committed Jun 30, 2015
2 parents 1bcc651 + 4874184 commit a2eee4e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Keter/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,9 @@ startListening KeterConfig {..} hostman = do
manager <- HTTP.newManager HTTP.conduitManagerSettings
runAndBlock kconfigListeners $ Proxy.reverseProxy
kconfigIpFromHeader
kconfigConnectionTimeBound
-- calculate the number of microseconds since the
-- configuration option is in milliseconds
(kconfigConnectionTimeBound * 1000)
manager
(HostMan.lookupAction hostman . CI.mk)

Expand Down
3 changes: 3 additions & 0 deletions Keter/Types/V04.hs
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ data KeterConfig = KeterConfig
, kconfigReverseProxy :: Set ReverseProxyConfig
, kconfigIpFromHeader :: Bool
, kconfigConnectionTimeBound :: Int
-- ^ Maximum request time in milliseconds per connection.
}

instance Default KeterConfig where
Expand All @@ -95,6 +96,8 @@ instance Default KeterConfig where
, kconfigConnectionTimeBound = fiveMinutes
}


-- | Default connection time bound in milliseconds.
fiveMinutes :: Int
fiveMinutes = 5 * 60 * 1000

Expand Down
1 change: 1 addition & 0 deletions Keter/Types/V10.hs
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ data KeterConfig = KeterConfig
, kconfigEnvironment :: !(Map Text Text)
-- ^ Environment variables to be passed to all apps.
, kconfigConnectionTimeBound :: !Int
-- ^ Maximum request time in milliseconds per connection.
}

instance ToCurrent KeterConfig where
Expand Down

0 comments on commit a2eee4e

Please sign in to comment.