micro-store-redis/options.go
Vasiliy Tolstov 00c4216ed2 use own fork
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2021-01-16 03:00:25 +03:00

19 lines
354 B
Go

package redis
import (
"github.com/go-redis/redis/v8"
"github.com/unistack-org/micro/v3/store"
)
type configKey struct{}
func Config(c *redis.Options) store.Option {
return store.SetOption(configKey{}, c)
}
type clusterConfigKey struct{}
func ClusterConfig(c *redis.ClusterOptions) store.Option {
return store.SetOption(clusterConfigKey{}, c)
}