MCPcopy Index your code
hub / github.com/argoproj/argo-cd / PatchAppWithWriteBack

Method PatchAppWithWriteBack

controller/appcontroller.go:1684–1691  ·  view source on GitHub ↗

PatchAppWithWriteBack patches an application and writes it back to the informer cache

(ctx context.Context, name, ns string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string)

Source from the content-addressed store, hash-verified

1682
1683// PatchAppWithWriteBack patches an application and writes it back to the informer cache
1684func (ctrl *ApplicationController) PatchAppWithWriteBack(ctx context.Context, name, ns string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *appv1.Application, err error) {
1685 patchedApp, err := ctrl.applicationClientset.ArgoprojV1alpha1().Applications(ns).Patch(ctx, name, pt, data, opts, subresources...)
1686 if err != nil {
1687 return patchedApp, err
1688 }
1689 ctrl.writeBackToInformer(patchedApp)
1690 return patchedApp, err
1691}
1692
1693func (ctrl *ApplicationController) processAppRefreshQueueItem() (processNext bool) {
1694 patchDuration := time.Duration(0) // time spent in doing patch/update calls

Callers 3

setOperationStateMethod · 0.95
normalizeApplicationMethod · 0.95
persistAppStatusMethod · 0.95

Calls 4

writeBackToInformerMethod · 0.95
PatchMethod · 0.65
ApplicationsMethod · 0.65
ArgoprojV1alpha1Method · 0.65

Tested by

no test coverage detected