Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 27 of 27 for removeContainers (0.19 sec)

  1. pkg/kubelet/kuberuntime/kuberuntime_container_test.go

    	expectedContainerLogSymlink := legacyLogSymlink(containerID, "foo", "bar", "new")
    
    	fakeOS.Create(expectedContainerLogPath)
    	fakeOS.Create(expectedContainerLogPathRotated)
    
    	err = m.removeContainer(ctx, containerID)
    	assert.NoError(t, err)
    
    	// Verify container log is removed.
    	// We could not predict the order of `fakeOS.Removes`, so we use `assert.ElementsMatch` here.
    	assert.ElementsMatch(t,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 22:40:29 UTC 2024
    - 28K bytes
    - Viewed (0)
  2. pkg/kubelet/cm/memorymanager/memory_manager_test.go

    			mgr.state.SetMemoryAssignments(testCase.assignments)
    			mgr.state.SetMachineState(testCase.machineState)
    
    			err := mgr.RemoveContainer(testCase.removeContainerID)
    			if !reflect.DeepEqual(err, testCase.expectedError) {
    				t.Errorf("Memory Manager RemoveContainer() error (%v), expected error: %v, but got: %v",
    					testCase.description, testCase.expectedError, err)
    			}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 05 13:01:40 UTC 2023
    - 70.2K bytes
    - Viewed (0)
  3. pkg/kubelet/cm/memorymanager/policy_static.go

    	if !ok {
    		return 0
    	}
    
    	return numaReusableMemory[resourceName]
    }
    
    // RemoveContainer call is idempotent
    func (p *staticPolicy) RemoveContainer(s state.State, podUID string, containerName string) {
    	blocks := s.GetMemoryBlocks(podUID, containerName)
    	if blocks == nil {
    		return
    	}
    
    	klog.InfoS("RemoveContainer", "podUID", podUID, "containerName", containerName)
    	s.Delete(podUID, containerName)
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Nov 12 07:34:55 UTC 2023
    - 34K bytes
    - Viewed (0)
  4. pkg/kubelet/cm/cpumanager/policy_static.go

    		if containerName == name {
    			continue
    		}
    		cset = cset.Union(cpus)
    	}
    	return cset
    }
    
    func (p *staticPolicy) RemoveContainer(s state.State, podUID string, containerName string) error {
    	klog.InfoS("Static policy: RemoveContainer", "podUID", podUID, "containerName", containerName)
    	cpusInUse := getAssignedCPUsOfSiblings(s, podUID, containerName)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Oct 06 13:16:15 UTC 2023
    - 28.8K bytes
    - Viewed (0)
  5. pkg/kubelet/kuberuntime/kuberuntime_gc.go

    				klog.ErrorS(err, "Failed to stop container", "containerID", containers[i].id)
    				continue
    			}
    		}
    		if err := cgc.manager.removeContainer(ctx, containers[i].id); err != nil {
    			klog.ErrorS(err, "Failed to remove container", "containerID", containers[i].id)
    		}
    	}
    
    	// Assume we removed the containers so that we're not too aggressive.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 04 06:25:43 UTC 2024
    - 15.3K bytes
    - Viewed (0)
  6. pkg/kubelet/kuberuntime/kuberuntime_gc_test.go

    	})
    	fakeRuntime.SetFakeContainers(fakeContainers)
    
    	err = m.containerGC.evictContainers(ctx, defaultGCPolicy, true, false)
    	assert.NoError(t, err)
    
    	assert.Contains(t, fakeRuntime.GetCalls(), "StopContainer", "RemoveContainer",
    		"container in unknown state should be stopped before being removed")
    
    	remain, err := fakeRuntime.ListContainers(ctx, nil)
    	assert.NoError(t, err)
    	assert.Empty(t, remain)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 08:12:16 UTC 2024
    - 20.6K bytes
    - Viewed (0)
  7. pkg/kubelet/cm/memorymanager/policy_static_test.go

    		t.Run(testCase.description, func(t *testing.T) {
    			p, s, err := initTests(t, &testCase, nil, nil)
    			if err != nil {
    				t.Fatalf("Unexpected error: %v", err)
    			}
    
    			p.RemoveContainer(s, "pod1", "container1")
    			assignments := s.GetMemoryAssignments()
    			if !areContainerMemoryAssignmentsEqual(t, assignments, testCase.expectedAssignments) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Sep 17 05:49:15 UTC 2023
    - 100.4K bytes
    - Viewed (0)
Back to top