Compare commits
1 Commits
Author | SHA1 | Date | |
---|---|---|---|
5f5ce49407 |
12
redis.go
12
redis.go
@@ -67,6 +67,18 @@ type Store struct {
|
||||
mu sync.RWMutex
|
||||
}
|
||||
|
||||
func (r *Store) Live() bool {
|
||||
return r.connected.Load() == 1
|
||||
}
|
||||
|
||||
func (r *Store) Ready() bool {
|
||||
return r.connected.Load() == 1
|
||||
}
|
||||
|
||||
func (r *Store) Health() bool {
|
||||
return r.connected.Load() == 1
|
||||
}
|
||||
|
||||
func (r *Store) Connect(ctx context.Context) error {
|
||||
if r.connected.Load() == 1 {
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user