-
Notifications
You must be signed in to change notification settings - Fork 44
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
cleanup: Stop updating ManageConflictErrors for a remote RSync #1538
base: main
Are you sure you want to change the base?
Conversation
Camila-B
commented
Feb 4, 2025
- Given fix: remediator management conflict detection #1342, this PR removes the requirement to report conflict errors to the remote manager in the reconciler when it's a RootSync
- b/355301118
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am currently reviewing this pull request. In the meanwhile, I am providing a summary of the content of the pull request for you and other reviewers to get up to speed quickly on the changes that have occurred, and the intent behind these changes.
Summary
This pull request addresses issue #1342 and b/355301118. The primary goal is to remove the requirement to report conflict errors to the remote manager in the reconciler when dealing with a RootSync. This change simplifies the error reporting mechanism and avoids unnecessary updates.
Changes
The following files were modified:
pkg/parse/root_sync_client.go
- The function
prependRootSyncRemediatorStatus
(lines 596-643) was removed. This function was responsible for adding conflict errors detected by the remediator to the front of the sync errors in the RootSync status.
- The function
pkg/parse/root_sync_client_test.go
- The import statements for
context
,github.com/stretchr/testify/require
,kpt.dev/configsync/pkg/applier
,kpt.dev/configsync/pkg/core
,kpt.dev/configsync/pkg/core/k8sobjects
,kpt.dev/configsync/pkg/metadata
,kpt.dev/configsync/pkg/rootsync
,kpt.dev/configsync/pkg/status
,kpt.dev/configsync/pkg/syncer/syncertest/fake
, andsigs.k8s.io/cli-utils/pkg/testutil
were removed (lines 18-32). - The test function
TestPrependRootSyncRemediatorStatus
(lines 464-577) was removed, as it tested the functionality of the now-removedprependRootSyncRemediatorStatus
function.
- The import statements for
pkg/parse/run.go
- The import statement for
kpt.dev/configsync/pkg/declared
was removed (line 29). - The call to
reportRootSyncConflicts
(lines 547-550) within thesetSyncStatus
function was removed. - The function
reportRootSyncConflicts
(lines 636-665) was removed. This function was responsible for reporting conflicts to the RootSync that manages the conflicting resources.
- The import statement for
In summary, this PR removes the logic for reporting conflict errors to the remote manager for RootSyncs, along with associated tests and dependencies.
Code conflicts arise,
RootSync's errors now subside,
A cleaner sync flows.
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This pull request removes the prependRootSyncRemediatorStatus
function and related logic, which was responsible for reporting conflict errors to the remote manager in the reconciler when it's a RootSync. The change is motivated by issue #1342 and aims to address b/355301118. Overall, the changes seem reasonable and well-targeted.
/lgtm Karl might have more context on this. |