Skip to content

Commit 4035de5

Browse files
authored
YAML tags for config. (#1007)
Sorry folks, not having a good day. Making a 4th PR for something dead simple. Apologies.
1 parent 56615aa commit 4035de5

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

webhook/resource_url_notifier.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ var (
4242
)
4343

4444
type ResourceURLNotifierConfig struct {
45-
MaxAge time.Duration
46-
MaxDepth int
45+
MaxAge time.Duration `yaml:"max_age,omitempty"`
46+
MaxDepth int `yaml:"max_depth,omitempty"`
4747
}
4848

4949
var DefaultResourceURLNotifierConfig = ResourceURLNotifierConfig{

webhook/url_notifier.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ const (
3838
)
3939

4040
type URLNotifierConfig struct {
41-
NumWorkers int
42-
QueueSize int
41+
NumWorkers int `yaml:"num_workers,omitempty"`
42+
QueueSize int `yaml:"queue_size,omitempty"`
4343
}
4444

4545
var DefaultURLNotifierConfig = URLNotifierConfig{

0 commit comments

Comments
 (0)