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

identity (CE): Persist conflict resolution after rename #29471

Merged
merged 5 commits into from
Feb 5, 2025

Conversation

banks
Copy link
Member

@banks banks commented Jan 31, 2025

Description

This PR ensures that automatic de-duplication is consistent across all
nodes in an Enterprise cluster by persisting conflict resolution on the
active node.

This logic to prevents Enterprise clusters from accidentally reverting
any conflict resolution after it's performed.

The PR includes some modifications to deterministic reload testing,
since they now have the side-effect of persistence on active nodes, as
well as tests for consistency in the face of storagePacker bucket
invalidation.

Enterprise PR: https://github.com/hashicorp/vault-enterprise/pull/7343
Resolves: VAULT-33555, VAULT-33504

TODO only if you're a HashiCorp employee

  • Backport Labels: If this fix needs to be backported, use the appropriate backport/ label that matches the desired release branch. Note that in the CE repo, the latest release branch will look like backport/x.x.x, but older release branches will be backport/ent/x.x.x+ent.
    • LTS: If this fixes a critical security vulnerability or severity 1 bug, it will also need to be backported to the current LTS versions of Vault. To ensure this, use all available enterprise labels.
  • ENT Breakage: If this PR either 1) removes a public function OR 2) changes the signature
    of a public function, even if that change is in a CE file, double check that
    applying the patch for this PR to the ENT repo and running tests doesn't
    break any tests. Sometimes ENT only tests rely on public functions in CE
    files.
  • Jira: If this change has an associated Jira, it's referenced either
    in the PR description, commit message, or branch name.
  • RFC: If this change has an associated RFC, please link it in the description.
  • ENT PR: If this change has an associated ENT PR, please link it in the
    description. Also, make sure the changelog is in this PR, not in your ENT PR.

@banks banks added this to the 1.19.0-rc milestone Jan 31, 2025
@github-actions github-actions bot added the hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed label Jan 31, 2025
Copy link

github-actions bot commented Jan 31, 2025

CI Results:
All Go tests succeeded! ✅

@mpalmi mpalmi force-pushed the id-dupe-invalidation-test branch 2 times, most recently from a5d0025 to 6ad4d93 Compare January 31, 2025 22:27
davidadeleon and others added 2 commits February 4, 2025 15:37
This PR introduces a test which exercises Vault's renameResolver and
asserts deterministic state after invalidation. To ensure that automatic
de-duplication is consistent across all nodes, we detect the node's
cluster status and persist renames IFF the node is active.

The PR includes some modifications to deterministic reload testing,
since they now have the side-effect of persistence on active nodes, as
well as tests for consistency in the face of storagePacker bucket
invalidation.
This commit introduces a random seed variable to be used with UUID
generation in Identity Store determinism tests. The seed is
automatically generated or passed during Environment Variable and
displayed during test failure. This allows for easy reproduction
of any test failures for later debugging.
@mpalmi mpalmi force-pushed the id-dupe-invalidation-test branch from 25f4ef6 to 95b0db7 Compare February 4, 2025 20:37
@mpalmi mpalmi changed the title Add CE changes for persisting renames identity (CE): Persist conflict resolution after rename Feb 4, 2025
@mpalmi mpalmi marked this pull request as ready for review February 4, 2025 21:29
@mpalmi mpalmi requested a review from a team as a code owner February 4, 2025 21:29
Copy link

github-actions bot commented Feb 4, 2025

Build Results:
All builds succeeded! ✅

biazmoreira
biazmoreira previously approved these changes Feb 5, 2025
davidadeleon
davidadeleon previously approved these changes Feb 5, 2025
@mpalmi mpalmi dismissed stale reviews from davidadeleon and biazmoreira via b88f102 February 5, 2025 14:24
@mpalmi mpalmi merged commit 6dc6929 into main Feb 5, 2025
91 of 92 checks passed
@mpalmi mpalmi deleted the id-dupe-invalidation-test branch February 5, 2025 15:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed pr/no-changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants