Skip to content

Commit

Permalink
Add small note about the (non) use of resource pool regarding databas…
Browse files Browse the repository at this point in the history
…e connection acquisition.
  • Loading branch information
KtorZ committed Feb 27, 2022
1 parent 73a653d commit d404ede
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Kupo.hs
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,11 @@ kupo tr@Tracers{tracerChainSync, tracerHttp, tracerDatabase} = hijackSigTerm *>
-- HTTP Server
( runServer
tracerHttp
-- NOTE: This should / could probably use a resource pool to
-- avoid re-creating a new connection on every requests. This is
-- however pretty cheap with SQLite anyway and the HTTP server
-- isn't meant to be a public-facing web server serving millions
-- of clients.
(withDatabase nullTracer ReadOnly lock longestRollback dbFile)
serverHost
serverPort
Expand Down

0 comments on commit d404ede

Please sign in to comment.