summaryrefslogtreecommitdiff
path: root/plugins/jobs/drivers/beanstalk/config.go
blob: caa683ab47a671e30eeb15d7a7b6e20ba5c33810 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package beanstalk

import "time"

type GlobalCfg struct {
	Addr    string        `mapstructure:"addr"`
	Timeout time.Duration `mapstructure:"timeout"`
}

func (c *GlobalCfg) InitDefault() {
	if c.Addr == "" {
		c.Addr = "tcp://localhost:11300"
	}

	if c.Timeout == 0 {
		c.Timeout = time.Second * 30
	}
}

type Config struct{}

func (c *Config) InitDefault() {}