From d7ff93b3bf9e577a2c135534a0adca3008d00ab6 Mon Sep 17 00:00:00 2001 From: "zhangyadong.0808" Date: Wed, 26 Jun 2024 17:36:13 +0800 Subject: [PATCH] feat(qrm): remove dropcache when migrate numa memory --- .../dynamicpolicy/policy_allocation_handlers.go | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/pkg/agent/qrm-plugins/memory/dynamicpolicy/policy_allocation_handlers.go b/pkg/agent/qrm-plugins/memory/dynamicpolicy/policy_allocation_handlers.go index 0f14c2f5d..266283fb0 100644 --- a/pkg/agent/qrm-plugins/memory/dynamicpolicy/policy_allocation_handlers.go +++ b/pkg/agent/qrm-plugins/memory/dynamicpolicy/policy_allocation_handlers.go @@ -29,7 +29,6 @@ import ( "github.com/kubewharf/katalyst-core/pkg/agent/qrm-plugins/memory/dynamicpolicy/state" "github.com/kubewharf/katalyst-core/pkg/agent/qrm-plugins/util" "github.com/kubewharf/katalyst-core/pkg/util/asyncworker" - cgroupmgr "github.com/kubewharf/katalyst-core/pkg/util/cgroup/manager" "github.com/kubewharf/katalyst-core/pkg/util/general" "github.com/kubewharf/katalyst-core/pkg/util/machine" qosutil "github.com/kubewharf/katalyst-core/pkg/util/qos" @@ -482,21 +481,6 @@ func (p *DynamicPolicy) adjustAllocationEntries() error { general.Errorf("add work: %s pod: %s container: %s failed with error: %v", movePagesWorkName, podUID, containerName, err) } } - - dropCacheWorkName := util.GetContainerAsyncWorkName(podUID, containerName, - memoryPluginAsyncWorkTopicDropCache) - // start a asynchronous work to drop cache for the container whose numaset changed and doesn't require numa_binding - err = p.defaultAsyncLimitedWorkers.AddWork( - &asyncworker.Work{ - Name: dropCacheWorkName, - UID: uuid.NewUUID(), - Fn: cgroupmgr.DropCacheWithTimeoutForContainer, - Params: []interface{}{podUID, containerID, dropCacheTimeoutSeconds, GetFullyDropCacheBytes(container)}, - DeliveredAt: time.Now(), - }, asyncworker.DuplicateWorkPolicyOverride) - if err != nil { - general.Errorf("add work: %s pod: %s container: %s failed with error: %v", dropCacheWorkName, podUID, containerName, err) - } } }