chore: reduce logging
This commit is contained in:
parent
88a124e8c2
commit
56e9212e65
@ -250,13 +250,13 @@ makeFoundation appSettings''@AppSettings{..} = do
|
||||
conn <- liftIO . PG.connectPostgreSQL $ pgConnStr appDatabaseConf
|
||||
backend <- liftIO $ openSimpleConn logFunc conn
|
||||
observeDatabaseConnectionOpened
|
||||
$logInfoS "SqlPool" "Opened connection"
|
||||
$logDebugS "SqlPool" "Opened connection"
|
||||
return backend
|
||||
destroy conn = do
|
||||
$logDebugS "SqlPool" "Closing connection..."
|
||||
liftIO $ connClose conn
|
||||
observeDatabaseConnectionClosed
|
||||
$logInfoS "SqlPool" "Closed connection"
|
||||
$logDebugS "SqlPool" "Closed connection"
|
||||
in Custom.createPool (liftIO . flip runLoggingT logFunc) create destroy (Just . fromIntegral $ pgPoolIdleTimeout appDatabaseConf) (Just $ pgPoolSize appDatabaseConf)
|
||||
let sqlPool :: forall m. MonadIO m => Custom.Pool m SqlBackend
|
||||
sqlPool = Custom.hoistPool (liftIO . flip runLoggingT logFunc) sqlPool'
|
||||
|
||||
Loading…
Reference in New Issue
Block a user