MCPcopy
hub / github.com/redis/go-redis / ExampleNewUniversalClient_simple

Function ExampleNewUniversalClient_simple

example_test.go:653–660  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

651}
652
653func ExampleNewUniversalClient_simple() {
654 rdb := redis.NewUniversalClient(&redis.UniversalOptions{
655 Addrs: []string{":6379"},
656 })
657 defer rdb.Close()
658
659 rdb.Ping(ctx)
660}
661
662func ExampleNewUniversalClient_failover() {
663 rdb := redis.NewUniversalClient(&redis.UniversalOptions{

Callers

nothing calls this directly

Calls 2

CloseMethod · 0.95
PingMethod · 0.65

Tested by

no test coverage detected