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

[main] added a debug log for conflict error and unit test for it #849

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

vardhaman22
Copy link
Contributor

@vardhaman22 vardhaman22 commented Feb 4, 2025

What this PR does / why we need it:
in case a conflict error occurs the controller's recordError Function will just print it and return the error as it is.

conflict errors occur since rancher also modifies aksconfig object. As conflict error returns empty object, errors like Error recording akscc [] failure message: resource name may not be empty occurs when we try to add a failure message to aksconfig status and update it.
The operation which results in conflict gets applied automatically in the next reconciliation call of the controller hence it is safe to just log it.

Which issue(s) this PR fixes
Issue #
#665

Special notes for your reviewer:

Checklist:

  • squashed commits into logical changes
  • includes documentation
  • adds unit tests
  • adds or updates e2e tests
  • backport needed

@vardhaman22 vardhaman22 marked this pull request as ready for review February 4, 2025 14:39
@vardhaman22 vardhaman22 requested review from a team as code owners February 4, 2025 14:39
@vardhaman22 vardhaman22 changed the title added a debug log for conflict error and unit test for it [main] added a debug log for conflict error and unit test for it Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants