Skip to content

Conversation

@Nkwenti-Severian-Ndongtsop
Copy link
Collaborator

What this PR does / why we need it:

This PR improves the user import process by gracefully handling password policy violations (e.g. password history limits) during user updates.

When Keycloak returns a password policy violation, the import now retries the update without the password, allowing the remaining user attributes to be updated successfully instead of failing the entire import.

Which issue this PR fixes

fixes #1112

Special notes for your reviewer:

  • The retry logic only applies to password policy violations; other 400 errors are re-thrown immediately
  • Non-password fields (email, firstName, lastName, etc.) are preserved during the retry
  • Unit testscover
    • The retry path when a password policy violation occurs
    • The normal path when the update succeeds without errors
  • This PR completes and supersedes the work originally started in branch

PR Readiness Checklist:

  • the CHANGELOG.md release notes have been updated to reflect any significant (and particularly user-facing) changes introduced by this PR

@Motouom Motouom moved this to In Progress in os-competence-center-board Jan 23, 2026
@Motouom Motouom moved this from In Progress to Review in os-competence-center-board Jan 23, 2026
@Nkwenti-Severian-Ndongtsop Nkwenti-Severian-Ndongtsop force-pushed the fix-1112-password-history-policy-failure branch from d568acf to fd74dcf Compare January 23, 2026 18:16
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

1 participant