Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨CreateOrPatch #850

Merged
merged 2 commits into from
Sep 25, 2020
Merged

Commits on Mar 10, 2020

  1. CreateOrPatch

    This patch introduces a variation on the controllerutil.CreateOrUpdate
    function named CreateOrPatch. Instead of issuing update calls, the new
    function uses a patch to perform a more surgical update to the remote
    data. Additionally, the implementation relies on logic similar to the
    PatchHelper mechanics in the Cluster API util/patch package. The
    resource is converted to unstructured data first in order to patch the
    resource and any potential status separately.
    
    Two new OperationResult values were added:
    
        1. OperationResultUpdatedStatus     - the resource and its status
                                              were updated
        2. OperationResultUpdatedStatusOnly - only the status was updated
    akutz committed Mar 10, 2020
    Configuration menu
    Copy the full SHA
    ae8a7c2 View commit details
    Browse the repository at this point in the history

Commits on Mar 11, 2020

  1. Add test to assert local copy updated post patch

    This patch adds a test to assert that the resource passed into
    CreateOrPatch is updated as part of the CreateOrPatch operation.
    akutz committed Mar 11, 2020
    Configuration menu
    Copy the full SHA
    196055a View commit details
    Browse the repository at this point in the history