默认不启用内存分片管理

This commit is contained in:
GoEdgeLab
2023-12-03 14:26:51 +08:00
parent cd51f220ba
commit 0e93f47906
3 changed files with 7 additions and 3 deletions

View File

@@ -517,7 +517,7 @@ func (this *MemoryStorage) flushItem(key string) {
_ = this.Delete(key)
// 重用内存,前提是确保内存不再被引用
if ok && item.IsDone && !item.isReferring && len(item.BodyValue) > 0 {
if enableFragmentPool && ok && item.IsDone && !item.isReferring && len(item.BodyValue) > 0 {
SharedFragmentMemoryPool.Put(item.BodyValue)
}
}()