forked from TrueCloudLab/frostfs-node
[#576] Set SyncWrites for badger writecache by default
Signed-off-by: Alejandro Lopez <a.lopez@yadro.com>
This commit is contained in:
parent
8d589314b5
commit
ae322e9f73
3 changed files with 1 additions and 13 deletions
|
@ -11,6 +11,7 @@ import (
|
|||
func OpenDB(p string, ro bool, l *logger.Logger) (*badger.DB, error) {
|
||||
return badger.Open(badger.DefaultOptions(p).
|
||||
WithReadOnly(ro).
|
||||
WithSyncWrites(true).
|
||||
WithLoggingLevel(badger.ERROR).
|
||||
WithLogger(badgerLoggerWrapper{l}))
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue