Function
makeCacheEntry
(zoneId string, name string)
Source from the content-addressed store, hash-verified
| 315 | } |
| 316 | |
| 317 | func makeCacheEntry(zoneId string, name string) *CacheEntry { |
| 318 | return &CacheEntry{ |
| 319 | Lock: &sync.Mutex{}, |
| 320 | ZoneId: zoneId, |
| 321 | Name: name, |
| 322 | PinCount: 0, |
| 323 | File: nil, |
| 324 | DataEntries: make(map[int]*DataCacheEntry), |
| 325 | FlushErrors: 0, |
| 326 | } |
| 327 | } |
| 328 | |
| 329 | func (entry *CacheEntry) flushToDB(ctx context.Context, replace bool) error { |
| 330 | if entry.File == nil { |
Tested by
no test coverage detected