Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 20 for CreateOrUpdate (0.26 sec)

  1. pkg/registry/core/service/portallocator/controller/repair_test.go

    	updated      *api.RangeAllocation
    	updateErr    error
    }
    
    func (r *mockRangeRegistry) Get() (*api.RangeAllocation, error) {
    	r.getCalled = true
    	return r.item, r.err
    }
    
    func (r *mockRangeRegistry) CreateOrUpdate(alloc *api.RangeAllocation) error {
    	r.updateCalled = true
    	r.updated = alloc
    	return r.updateErr
    }
    
    func TestRepair(t *testing.T) {
    	clearMetrics()
    	fakeClient := fake.NewSimpleClientset()
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Sep 30 15:46:06 UTC 2023
    - 10.6K bytes
    - Viewed (0)
  2. pkg/registry/core/service/portallocator/controller/repair.go

    	})
    
    	// Blast the rebuilt state into storage.
    	if err := rebuilt.Snapshot(snapshot); err != nil {
    		return fmt.Errorf("unable to snapshot the updated port allocations: %v", err)
    	}
    
    	if err := c.alloc.CreateOrUpdate(snapshot); err != nil {
    		if errors.IsConflict(err) {
    			return err
    		}
    		return fmt.Errorf("unable to persist the updated port allocations: %v", err)
    	}
    	return nil
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Sep 30 15:46:06 UTC 2023
    - 10.4K bytes
    - Viewed (0)
  3. pilot/pkg/serviceregistry/kube/controller/controller_test.go

    			Labels:    labels,
    		},
    		Subsets: []corev1.EndpointSubset{{
    			Addresses: eas,
    			Ports:     eps,
    		}},
    	}
    	clienttest.NewWriter[*corev1.Endpoints](t, controller.client).CreateOrUpdate(endpoint)
    
    	// Create endpoint slice as well
    	esps := make([]discovery.EndpointPort, 0)
    	for _, name := range portNames {
    		n := name // Create a stable reference to take the pointer from
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu May 23 21:07:03 UTC 2024
    - 85K bytes
    - Viewed (0)
  4. pkg/registry/core/service/ipallocator/controller/repair.go

    	if err := rebuilt.Snapshot(snapshot); err != nil {
    		return fmt.Errorf("unable to snapshot the updated service IP allocations: %v", err)
    	}
    	if err := alloc.CreateOrUpdate(snapshot); err != nil {
    		if errors.IsConflict(err) {
    			return err
    		}
    		return fmt.Errorf("unable to persist the updated service IP allocations: %v", err)
    	}
    
    	return nil
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Sep 30 15:46:06 UTC 2023
    - 13.8K bytes
    - Viewed (0)
  5. pilot/pkg/serviceregistry/kube/controller/pod_test.go

    	assert.Equal(t, got != nil, true)
    	assert.Equal(t, map[string]string{"app": "test", "foo": "bar"}, got[0].Labels)
    
    	pod.Labels["foo"] = "not-bar"
    	clienttest.Wrap(t, c.podsClient).CreateOrUpdate(pod)
    	fx.StrictMatchOrFail(t, xdsfake.Event{
    		Type: "proxy",
    		ID:   "128.0.0.1",
    	},
    		xdsfake.Event{
    			Type: "xds",
    			ID:   "ratings.nsa.svc.company.com",
    		})
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Apr 16 18:27:40 UTC 2024
    - 12.3K bytes
    - Viewed (0)
  6. pkg/kube/multicluster/secretcontroller_test.go

    			Synced: atomic.NewBool(synced),
    		}
    	})
    	return tc
    }
    
    var kubeconfig = 0
    
    func (t *testController) AddSecret(secretName, clusterID string) {
    	kubeconfig++
    	t.secrets.CreateOrUpdate(makeSecret(secretNamespace, secretName, clusterCredential{clusterID, []byte(fmt.Sprintf("kubeconfig-%d", kubeconfig))}))
    }
    
    func (t *testController) DeleteSecret(secretName string) {
    	t.t.Helper()
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu May 23 15:07:03 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  7. pilot/pkg/serviceregistry/kube/controller/ambient/ambientindex_workloadentry_test.go

    	s.assertAddresses(t, "", "name1", "name2", "name3", "waypoint-ns-pod")
    	s.assertEvent(t, s.podXdsName("waypoint-ns-pod"))
    	s.addWaypoint(t, "10.0.0.2", "waypoint-ns", constants.AllTraffic, true)
    	s.ns.CreateOrUpdate(&corev1.Namespace{
    		ObjectMeta: metav1.ObjectMeta{
    			Name: testNS,
    			Labels: map[string]string{
    				constants.AmbientUseWaypointLabel: "waypoint-ns",
    			},
    		},
    	})
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed May 08 01:04:50 UTC 2024
    - 15.6K bytes
    - Viewed (0)
  8. pkg/registry/core/service/ipallocator/controller/repair_test.go

    	updated      *api.RangeAllocation
    	updateErr    error
    }
    
    func (r *mockRangeRegistry) Get() (*api.RangeAllocation, error) {
    	r.getCalled = true
    	return r.item, r.err
    }
    
    func (r *mockRangeRegistry) CreateOrUpdate(alloc *api.RangeAllocation) error {
    	r.updateCalled = true
    	r.updated = alloc
    	return r.updateErr
    }
    
    func TestRepair(t *testing.T) {
    	fakeClient := fake.NewSimpleClientset()
    	ipregistry := &mockRangeRegistry{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Sep 30 15:46:06 UTC 2023
    - 21.1K bytes
    - Viewed (0)
  9. CHANGELOG/CHANGELOG-1.16.md

    - Switch to VM Update call in attach/detach disk operation, original CreateOrUpdate call may lead to orphaned VMs or blocked resources ([#81208](https://github.com/kubernetes/kubernetes/pull/81208), [@andyzhangx](https://github.com/andyzhangx))
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Feb 11 10:00:57 UTC 2021
    - 345.2K bytes
    - Viewed (0)
  10. CHANGELOG/CHANGELOG-1.15.md

    * switch to VM Update call in attach/detach disk operation, original CreateOrUpdate call may lead to orphaned VMs or blocked resources ([#81208](https://github.com/kubernetes/kubernetes/pull/81208), [@andyzhangx](https://github.com/andyzhangx))
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 05 13:44:43 UTC 2022
    - 278.9K bytes
    - Viewed (0)
Back to top