Skip to content

Commit

Permalink
remove useless functions
Browse files Browse the repository at this point in the history
  • Loading branch information
waynepeking348 committed May 31, 2023
1 parent 1e0f579 commit e65f7c9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -598,9 +598,3 @@ func (p *DynamicPolicy) applyBlocks(blockCPUSet advisorapi.BlockCPUSet, resp *ad

return nil
}

// qrmGeneratedInfo returns true if the allocation info in state should be
// initialized by qrm rather than advisor
func qrmGeneratedInfo(subEntry string, info *advisorapi.CalculationInfo) bool {
return info.OwnerPoolName == state.PoolNameDedicated || subEntry != advisorapi.FakedContainerName
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ import (
"fmt"
"time"

"k8s.io/apimachinery/pkg/util/sets"

"github.com/kubewharf/katalyst-api/pkg/consts"
advisorapi "github.com/kubewharf/katalyst-core/pkg/agent/qrm-plugins/cpu/dynamicpolicy/cpuadvisor"
"github.com/kubewharf/katalyst-core/pkg/agent/qrm-plugins/cpu/dynamicpolicy/state"
Expand All @@ -30,7 +32,6 @@ import (
cgroupcmutils "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"
"k8s.io/apimachinery/pkg/util/sets"
)

// checkCPUSet emit errors if the memory allocation falls into unexpected results
Expand Down
3 changes: 2 additions & 1 deletion pkg/agent/qrm-plugins/memory/dynamicpolicy/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@ import (
"math"

info "github.com/google/cadvisor/info/v1"
"github.com/kubewharf/katalyst-core/pkg/util/general"
"k8s.io/apimachinery/pkg/api/resource"

"github.com/kubewharf/katalyst-core/pkg/util/general"
)

// GetReservedMemory is used to spread total reserved memories into per-numa level.
Expand Down

0 comments on commit e65f7c9

Please sign in to comment.