MCPcopy Create free account
hub / github.com/DoNewsCode/core / WithConfigInterceptor

Function WithConfigInterceptor

otredis/dependency_option.go:23–27  ·  view source on GitHub ↗

WithConfigInterceptor instructs the Providers to accept the RedisConfigurationInterceptor so that users can change config during runtime. This can be useful when some dynamic computations on configs are required.

(interceptor RedisConfigurationInterceptor)

Source from the content-addressed store, hash-verified

21// RedisConfigurationInterceptor so that users can change config during runtime. This can
22// be useful when some dynamic computations on configs are required.
23func WithConfigInterceptor(interceptor RedisConfigurationInterceptor) ProvidersOptionFunc {
24 return func(options *providersOption) {
25 options.interceptor = interceptor
26 }
27}
28
29// WithReload toggles whether the factory should reload cached instances upon
30// OnReload event.

Callers 1

Calls

no outgoing calls

Tested by 1