Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 102 for PodList (0.1 sec)

  1. pkg/kube/kclient/clienttest/direct.go

    // However, NewDirectClient can be useful if we do not need/want an informer and need direct reads.
    // Generic parameters represent the type with and without a pointer, and the list type.
    // Example: NewDirectClient[*Pod, Pod, PodList]
    func NewDirectClient[T controllers.ComparableObject, PT any, TL runtime.Object](t test.Failer, c kube.Client) TestClient[T] {
    	return WrapReadWriter[T](t, &directClient[T, PT, TL]{
    		t:      t,
    		client: c,
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Aug 08 16:43:05 UTC 2023
    - 3K bytes
    - Viewed (0)
  2. staging/src/k8s.io/cli-runtime/pkg/printers/bench_test.go

    	"k8s.io/client-go/kubernetes/scheme"
    )
    
    func newBenchmarkList() *unstructured.UnstructuredList {
    	list := &unstructured.UnstructuredList{
    		Object: map[string]interface{}{
    			"apiVersion": "v1",
    			"kind":       "PodList",
    		},
    		Items: []unstructured.Unstructured{},
    	}
    	for i := 0; i < 1000; i++ {
    		list.Items = append(list.Items, unstructured.Unstructured{
    			Object: map[string]interface{}{
    				"apiVersion": "v1",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Mar 30 00:36:07 UTC 2022
    - 4.2K bytes
    - Viewed (0)
  3. pkg/controller/volume/attachdetach/attach_detach_controller_test.go

    		i++
    	}
    	i = 0
    	podList, err := informerFactory.Core().V1().Pods().Lister().List(labels.Everything())
    	for len(podList) < podsNum {
    		if err != nil {
    			t.Fatalf("Error getting list of nodes %v", err)
    		}
    		if i > 100 {
    			t.Fatalf("Time out while waiting for the pod informer sync: found %d pods, expected %d pods", len(podList), podsNum)
    		}
    		time.Sleep(100 * time.Millisecond)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 18 11:00:37 UTC 2024
    - 24.2K bytes
    - Viewed (0)
  4. pkg/controller/volume/attachdetach/testing/testvolumespec.go

    func CreateTestClient() *fake.Clientset {
    	var extraPods *v1.PodList
    	var volumeAttachments *storagev1.VolumeAttachmentList
    	var pvs *v1.PersistentVolumeList
    	var nodes *v1.NodeList
    
    	fakeClient := &fake.Clientset{}
    
    	extraPods = &v1.PodList{}
    	fakeClient.AddReactor("list", "pods", func(action core.Action) (handled bool, ret runtime.Object, err error) {
    		obj := &v1.PodList{}
    		podNamePrefix := "mypod"
    		namespace := "mynamespace"
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Nov 17 08:48:30 UTC 2023
    - 16.5K bytes
    - Viewed (0)
  5. pkg/kubelet/config/file_linux.go

    			}
    		}
    	}, retryPeriod)
    }
    
    func (s *sourceFile) doWatch() error {
    	_, err := os.Stat(s.path)
    	if err != nil {
    		if !os.IsNotExist(err) {
    			return err
    		}
    		// Emit an update with an empty PodList to allow FileSource to be marked as seen
    		s.updates <- kubetypes.PodUpdate{Pods: []*v1.Pod{}, Op: kubetypes.SET, Source: kubetypes.FileSource}
    		return &retryableError{"path does not exist, ignoring"}
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 02 17:27:26 UTC 2023
    - 3.8K bytes
    - Viewed (0)
  6. src/internal/coverage/cfile/testsupport.go

    	// expect to see a single pod here, but allow for multiple pods in
    	// case the test harness is doing extra work to collect data files
    	// from builds that it kicks off as part of the testing.
    	podlist, err := pods.CollectPods([]string{dir}, false)
    	if err != nil {
    		return fmt.Errorf("reading from %s: %v", dir, err)
    	}
    
    	// Open text output file if appropriate.
    	var tf *os.File
    	var tfClosed bool
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 09:57:47 UTC 2024
    - 8.7K bytes
    - Viewed (0)
  7. pkg/scheduler/scheduler_test.go

    func getPodFromPriorityQueue(queue *internalqueue.PriorityQueue, pod *v1.Pod) *v1.Pod {
    	podList, _ := queue.PendingPods()
    	if len(podList) == 0 {
    		return nil
    	}
    
    	queryPodKey, err := cache.MetaNamespaceKeyFunc(pod)
    	if err != nil {
    		return nil
    	}
    
    	for _, foundPod := range podList {
    		foundPodKey, err := cache.MetaNamespaceKeyFunc(foundPod)
    		if err != nil {
    			return nil
    		}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 17 09:07:27 UTC 2024
    - 42K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store_test.go

    		},
    		"normalFiltered": {
    			in:  &example.PodList{Items: []example.Pod{*podA, *podB}},
    			m:   matchPodName("foo"),
    			out: &example.PodList{Items: []example.Pod{*podB}},
    		},
    		"normalFilteredNoNamespace": {
    			in:      &example.PodList{Items: []example.Pod{*podA, *podB}},
    			m:       matchPodName("foo"),
    			out:     &example.PodList{Items: []example.Pod{*podB}},
    			context: noNamespaceContext,
    		},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jun 12 10:12:02 UTC 2024
    - 101.8K bytes
    - Viewed (0)
  9. cmd/kubeadm/app/util/etcd/etcd.go

    	podList, err := client.CoreV1().Pods(metav1.NamespaceSystem).List(
    		context.TODO(),
    		metav1.ListOptions{
    			LabelSelector: fmt.Sprintf("component=%s,tier=%s", constants.Etcd, constants.ControlPlaneTier),
    		},
    	)
    	if err != nil {
    		return []string{}, 0, err
    	}
    	etcdEndpoints := []string{}
    	for _, pod := range podList.Items {
    		podIsReady := false
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Mar 01 11:04:08 UTC 2024
    - 21.2K bytes
    - Viewed (0)
  10. pkg/kubelet/container/testing/fake_runtime.go

    }
    
    type FakePod struct {
    	Pod       *kubecontainer.Pod
    	NetnsPath string
    }
    
    // FakeRuntime is a fake container runtime for testing.
    type FakeRuntime struct {
    	sync.Mutex
    	CalledFunctions   []string
    	PodList           []*FakePod
    	AllPodList        []*FakePod
    	ImageList         []kubecontainer.Image
    	ImageFsStats      []*runtimeapi.FilesystemUsage
    	ContainerFsStats  []*runtimeapi.FilesystemUsage
    	APIPodStatus      v1.PodStatus
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Feb 14 00:23:50 UTC 2024
    - 13.9K bytes
    - Viewed (0)
Back to top