MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / CloseAll

Method CloseAll

internal/caches/open_file_cache.go:150–161  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

148}
149
150func (this *OpenFileCache) CloseAll() {
151 this.locker.Lock()
152 for _, pool := range this.poolMap {
153 pool.Close()
154 }
155 this.poolMap = map[string]*OpenFilePool{}
156 this.poolList.Reset()
157 _ = this.watcher.Close()
158 this.count = 0
159 this.usedSize = 0
160 this.locker.Unlock()
161}
162
163func (this *OpenFileCache) SetCapacity(capacityBytes int64) {
164 this.capacitySize = capacityBytes

Callers 3

StopMethod · 0.80
initOpenFileCacheMethod · 0.80

Calls 4

CloseMethod · 0.65
ResetMethod · 0.65
LockMethod · 0.45
UnlockMethod · 0.45

Tested by 1