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

ssa/jsondiff: cluster and desired object in Diff #691

Merged
merged 1 commit into from
Nov 27, 2023
Merged

Conversation

hiddeco
Copy link
Member

@hiddeco hiddeco commented Nov 27, 2023

By including the objects in full, it becomes possible to for example apply the JSON Patch without having to retrieve the object again.

In addition, it becomes possible to e.g. render a diff including any ignore rules (using dyff) by applying the JSON Patch to a copy of the cluster object.

Note that when you want to use the JSON Patch result to perform an actual patch operation, any Secret masking should be done while displaying information and not using the available option. As otherwise the patch would be issued with masked data (and potentially illegal base64 payloads).

By including the objects in full, it becomes possible to for example
apply the JSON Patch without having to retrieve the object again.

In addition, it becomes possible to e.g. render a diff including any
ignore rules (using dyff) by applying the JSON Patch to a copy of the
cluster object.

Note that when you want to use the JSON Patch result to perform an
actual patch operation, any Secret masking should be done while
displaying information and not using the available option. As otherwise
the patch would be issued with masked data (and potentially illegal
base64 payloads).

Signed-off-by: Hidde Beydals <hidde@hhh.computer>
@hiddeco hiddeco added enhancement New feature or request area/server-side-apply SSA related issues and pull requests labels Nov 27, 2023
Copy link
Member

@stefanprodan stefanprodan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Thanks @hiddeco

@hiddeco hiddeco merged commit cc07605 into main Nov 27, 2023
13 checks passed
@hiddeco hiddeco deleted the jsondiff-include-obj branch November 27, 2023 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/server-side-apply SSA related issues and pull requests enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants