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

Method FindStorageWithPolicy

internal/caches/manager.go:171–176  ·  view source on GitHub ↗

FindStorageWithPolicy 根据策略ID查找存储

(policyId int64)

Source from the content-addressed store, hash-verified

169
170// FindStorageWithPolicy 根据策略ID查找存储
171func (this *Manager) FindStorageWithPolicy(policyId int64) StorageInterface {
172 this.locker.RLock()
173 defer this.locker.RUnlock()
174
175 return this.storageMap[policyId]
176}
177
178// NewStorageWithPolicy 根据策略获取存储对象
179func (this *Manager) NewStorageWithPolicy(policy *serverconfigs.HTTPCachePolicy) StorageInterface {

Callers 3

PrepareCacheMethod · 0.80
doCacheReadMethod · 0.80
cacheStorageMethod · 0.80

Calls 2

RLockMethod · 0.80
RUnlockMethod · 0.80

Tested by

no test coverage detected