Store implements Cache.
(ctx context.Context, keys []string, values [][]byte)
| 195 | |
| 196 | // Store implements Cache. |
| 197 | func (c *FifoCache) Store(ctx context.Context, keys []string, values [][]byte) { |
| 198 | c.entriesAdded.Inc() |
| 199 | |
| 200 | c.lock.Lock() |
| 201 | defer c.lock.Unlock() |
| 202 | |
| 203 | for i := range keys { |
| 204 | c.put(keys[i], values[i]) |
| 205 | } |
| 206 | } |
| 207 | |
| 208 | // Stop implements Cache. |
| 209 | func (c *FifoCache) Stop() { |