File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -82,7 +82,8 @@ type Cache struct {
8282}
8383
8484type PubSub struct {
85- URL string `yaml:"url" envconfig:"PUBSUB__URL"`
85+ URL string `yaml:"url" envconfig:"PUBSUB__URL"`
86+ BufferSize uint `yaml:"buffer_size" envconfig:"PUBSUB__BUFFER_SIZE"`
8687}
8788
8889func Default () Config {
@@ -119,7 +120,8 @@ func Default() Config {
119120 URL : "memory://" ,
120121 },
121122 PubSub : PubSub {
122- URL : "memory://" ,
123+ URL : "memory://" ,
124+ BufferSize : 128 ,
123125 },
124126 }
125127}
Original file line number Diff line number Diff line change @@ -115,7 +115,7 @@ func Module() fx.Option {
115115 ) * time .Second ,
116116 }
117117 }),
118- fx .Provide (func (cfg Config ) devices.Config {
118+ fx .Provide (func (_ Config ) devices.Config {
119119 return devices.Config {
120120 UnusedLifetime : 365 * 24 * time .Hour , //TODO: make it configurable
121121 }
@@ -133,7 +133,7 @@ func Module() fx.Option {
133133 fx .Provide (func (cfg Config ) pubsub.Config {
134134 return pubsub.Config {
135135 URL : cfg .PubSub .URL ,
136- BufferSize : 128 ,
136+ BufferSize : cfg . PubSub . BufferSize ,
137137 }
138138 }),
139139 )
You can’t perform that action at this time.
0 commit comments