summaryrefslogtreecommitdiffstats
path: root/modules/setting/database.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/setting/database.go')
-rw-r--r--modules/setting/database.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/setting/database.go b/modules/setting/database.go
index 911ac90a05..85043e8c11 100644
--- a/modules/setting/database.go
+++ b/modules/setting/database.go
@@ -126,7 +126,7 @@ func DBConnStr() (string, error) {
if err := os.MkdirAll(path.Dir(Database.Path), os.ModePerm); err != nil {
return "", fmt.Errorf("Failed to create directories: %v", err)
}
- connStr = fmt.Sprintf("file:%s?cache=shared&mode=rwc&_busy_timeout=%d", Database.Path, Database.Timeout)
+ connStr = fmt.Sprintf("file:%s?cache=shared&mode=rwc&_busy_timeout=%d&_txlock=immediate", Database.Path, Database.Timeout)
default:
return "", fmt.Errorf("Unknown database type: %s", Database.Type)
}