summaryrefslogtreecommitdiff
path: root/plugins/kv/drivers/boltdb/config.go
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/kv/drivers/boltdb/config.go')
-rw-r--r--plugins/kv/drivers/boltdb/config.go15
1 files changed, 4 insertions, 11 deletions
diff --git a/plugins/kv/drivers/boltdb/config.go b/plugins/kv/drivers/boltdb/config.go
index ebe73c25..0beb209b 100644
--- a/plugins/kv/drivers/boltdb/config.go
+++ b/plugins/kv/drivers/boltdb/config.go
@@ -1,34 +1,27 @@
package boltdb
type Config struct {
- // Dir is a directory to store the DB files
- Dir string
// File is boltDB file. No need to create it by your own,
// boltdb driver is able to create the file, or read existing
File string
// Bucket to store data in boltDB
- Bucket string
+ bucket string
// db file permissions
Permissions int
// timeout
- Interval uint `mapstructure:"interval"`
+ Interval int `mapstructure:"interval"`
}
// InitDefaults initializes default values for the boltdb
func (s *Config) InitDefaults() {
- if s.Dir == "" {
- s.Dir = "." // current dir
- }
- if s.Bucket == "" {
- s.Bucket = "rr" // default bucket name
- }
+ s.bucket = "default"
if s.File == "" {
s.File = "rr.db" // default file name
}
if s.Permissions == 0 {
- s.Permissions = 777 // free for all
+ s.Permissions = 0777 // free for all
}
if s.Interval == 0 {