- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 11 for GuaranteedUpdate (0.28 sec)
-
staging/src/k8s.io/apiserver/pkg/storage/testing/watcher_tests.go
badOut := &example.Pod{} err = store.GuaranteedUpdate(ctx, badKey, badOut, true, nil, storage.SimpleUpdate( func(runtime.Object) (runtime.Object, error) { obj := basePod.DeepCopy() obj.Namespace = fmt.Sprintf("%s-bad", tt.namespace) return obj, nil }), nil) if err != nil { t.Fatalf("GuaranteedUpdate of bad pod failed: %v", err) } var prevObj *example.Pod
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 63.8K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/testing/store_tests.go
return input, nil, nil } // GuaranteedUpdate without suggestion should return an error if err := store.GuaranteedUpdate(ctx, preset[1].key, &example.Pod{}, false, nil, updateFunc, nil); !storage.IsInternalError(err) { t.Errorf("Unexpected error: %v", err) } // GuaranteedUpdate with suggestion should return an error if we don't change the object
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jun 11 12:45:33 UTC 2024 - 91.4K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/interfaces.go
type MatchValue struct { IndexName string Value string } // Pass an UpdateFunc to Interface.GuaranteedUpdate to make an update // that is guaranteed to succeed. // See the comment for GuaranteedUpdate for more details. type UpdateFunc func(input runtime.Object, res ResponseMeta) (output runtime.Object, ttl *uint64, err error)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Apr 29 07:53:48 UTC 2024 - 14.8K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/etcd3/store.go
if err != nil { recordDecodeError(s.groupResourceString, key) return err } return nil } } // GuaranteedUpdate implements storage.Interface.GuaranteedUpdate. func (s *store) GuaranteedUpdate( ctx context.Context, key string, destination runtime.Object, ignoreNotFound bool,
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri May 10 11:56:42 UTC 2024 - 35.2K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/etcd3/store_test.go
expectInvalidKey("Get", store.Get(ctx, invalidKey, storage.GetOptions{}, nil)) expectInvalidKey("GetList", store.GetList(ctx, invalidKey, storage.ListOptions{}, nil)) expectInvalidKey("GuaranteedUpdate", store.GuaranteedUpdate(ctx, invalidKey, nil, true, nil, nil, nil)) _, countErr := store.Count(invalidKey) expectInvalidKey("Count", countErr) } func TestResolveGetListRev(t *testing.T) { _, store, _ := testSetup(t)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jun 11 12:45:33 UTC 2024 - 26.5K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/endpoints/handlers/patch.go
return err } return nil } // applyPatch is called every time GuaranteedUpdate asks for the updated object, // and is given the currently persisted object as input. // TODO: rename this function because the name implies it is related to applyPatcher
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue May 28 08:48:22 UTC 2024 - 28.5K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/cacher/cacher.go
return err } } metrics.RecordListCacheMetrics(c.resourcePrefix, indexUsed, len(objs), listVal.Len()) return nil } // GuaranteedUpdate implements storage.Interface. func (c *Cacher) GuaranteedUpdate( ctx context.Context, key string, destination runtime.Object, ignoreNotFound bool, preconditions *storage.Preconditions, tryUpdate storage.UpdateFunc, _ runtime.Object) error {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Jun 12 10:12:02 UTC 2024 - 51.8K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/endpoints/handlers/rest_test.go
// Simulate GuaranteedUpdate behavior (retries internally on etcd changes if the incoming resource doesn't pin resourceVersion) for { currentPod := p.startingPod if p.numUpdates > 0 { currentPod = p.updatePod } p.numUpdates++
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue May 28 08:48:22 UTC 2024 - 41.8K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store_test.go
cachedObj runtime.Object } // GuaranteedUpdate overwrites the method with one that always suggests the cachedObj. func (s *staleGuaranteedUpdateStorage) GuaranteedUpdate( ctx context.Context, key string, destination runtime.Object, ignoreNotFound bool, preconditions *storage.Preconditions, tryUpdate storage.UpdateFunc, _ runtime.Object) error {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Jun 12 10:12:02 UTC 2024 - 101.8K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/registry/generic/registry/store.go
storagePreconditions.ResourceVersion = preconditions.ResourceVersion } out := e.NewFunc() // deleteObj is only used in case a deletion is carried out var deleteObj runtime.Object err = e.Storage.GuaranteedUpdate(ctx, key, out, true, storagePreconditions, func(existing runtime.Object, res storage.ResponseMeta) (runtime.Object, *uint64, error) { existingResourceVersion, err := e.Storage.Versioner().ObjectResourceVersion(existing)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Jan 19 23:22:44 UTC 2024 - 60.8K bytes - Viewed (0)