mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-20 18:31:15 +00:00
node: topology-mgr: code optimization
Signed-off-by: Swati Sehgal <swsehgal@redhat.com>
This commit is contained in:
parent
cf21dcef51
commit
8442b450e5
@ -211,10 +211,9 @@ func (m *manager) RemoveContainer(containerID string) error {
|
||||
func (m *manager) Admit(attrs *lifecycle.PodAdmitAttributes) lifecycle.PodAdmitResult {
|
||||
klog.InfoS("Topology Admit Handler")
|
||||
metrics.TopologyManagerAdmissionRequestsTotal.Inc()
|
||||
pod := attrs.Pod
|
||||
|
||||
startTime := time.Now()
|
||||
podAdmitResult := m.scope.Admit(pod)
|
||||
podAdmitResult := m.scope.Admit(attrs.Pod)
|
||||
metrics.TopologyManagerAdmissionDuration.Observe(float64(time.Since(startTime).Milliseconds()))
|
||||
|
||||
return podAdmitResult
|
||||
|
Loading…
Reference in New Issue
Block a user