Skip to content

Commit b4c1a96

Browse files
committed
Set DB conn reuse timeout
Signed-off-by: Carlos Martín <[email protected]> sq me
1 parent 687e5df commit b4c1a96

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

cmd/gitbase-web/main.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ func (c *ServeCommand) Execute(args []string) error {
5151
}
5252
defer db.Close()
5353

54+
db.SetMaxIdleConns(0)
55+
5456
static := handler.NewStatic("build/public", c.ServerURL, c.SelectLimit, c.FooterHTML)
5557

5658
// start the router

0 commit comments

Comments
 (0)