summaryrefslogtreecommitdiff
path: root/plugins/kv/boltdb/config.go
diff options
context:
space:
mode:
authorValery Piashchynski <[email protected]>2021-01-07 01:06:50 +0300
committerValery Piashchynski <[email protected]>2021-01-07 01:06:50 +0300
commitc1465d3bcdf24a78440300aa51e7cfc92ce874a8 (patch)
tree6e0f5107eba90df73724b6611ca6adfa148d2a3f /plugins/kv/boltdb/config.go
parentc9f670ee734355cbc5d504186946b7db67cf62b5 (diff)
KV, updated, bug fixed, with intergration tests via plugins
Diffstat (limited to 'plugins/kv/boltdb/config.go')
-rw-r--r--plugins/kv/boltdb/config.go11
1 files changed, 6 insertions, 5 deletions
diff --git a/plugins/kv/boltdb/config.go b/plugins/kv/boltdb/config.go
index 6b116611..b2e1e636 100644
--- a/plugins/kv/boltdb/config.go
+++ b/plugins/kv/boltdb/config.go
@@ -8,16 +8,17 @@ type Config struct {
File string
// Bucket to store data in boltDB
Bucket string
-
+ // db file permissions
Permissions int
- TTL int
+ // timeout
+ Interval uint `yaml:"interval"`
}
-func (s *Config) InitDefaults() error {
+// InitDefaults initializes default values for the boltdb
+func (s *Config) InitDefaults() {
s.Dir = "." // current dir
s.Bucket = "rr" // default bucket name
s.File = "rr.db" // default file name
s.Permissions = 0777 // free for all
- s.TTL = 60 // 60 seconds is default TTL
- return nil
+ s.Interval = 60 // default is 60 seconds timeout
}