Skip to content

Commit

Permalink
fix(processor): limit db to one connection (Cloudbox#43)
Browse files Browse the repository at this point in the history
Limiting the database to one connection should resolve the "database is locked" error for processor operations.
  • Loading branch information
m-rots authored Sep 10, 2020
1 parent 99ea549 commit 57455d0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions processor/datastore.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ func newDatastore(path string) (*datastore, error) {
return nil, err
}

db.SetMaxOpenConns(1)

_, err = db.Exec(sqlSchema)
if err != nil {
return nil, err
Expand Down

0 comments on commit 57455d0

Please # to comment.