(key string)
| 255 | } |
| 256 | |
| 257 | func (c *Client) Exists(key string) (bool, error) { |
| 258 | client, err := newGrpcClient(c.Addr) |
| 259 | if err != nil { |
| 260 | return false, nil |
| 261 | } |
| 262 | resp, err := client.Exists(context.Background(), &gstring.ExistsRequest{Key: key}) |
| 263 | if err != nil { |
| 264 | return false, nil |
| 265 | } |
| 266 | return resp.Exists, nil |
| 267 | } |
| 268 | |
| 269 | func (c *Client) Expire(key string, ttl int64) error { |
| 270 | client, err := newGrpcClient(c.Addr) |
nothing calls this directly
no test coverage detected