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

Make framework.WALPrefix a local path #137

Merged
merged 3 commits into from
Oct 16, 2023

Conversation

Zlaticanin
Copy link
Contributor

The WAL rollback process for plugins is a way to have plugins cleanup external state from any failed requests. The intention is that, whenever a request comes in, the plugin is responsible for writing to framework.PutWAL() with some data, and then end a request by calling framework.DeleteWAL() to delete the data. If the request fails partway through, then DeleteWAL never gets called.
This PR makes framework.WALPrefix to be a local path so that performance secondaries wouldn't end up with the WAL data getting replicated.

Before fix:

2023-10-13T16:41:33.979-0700 [DEBUG] perf-pri.core0.auth.local-azure.auth_local-azure_b0e813b6.local-azure.vault-plugin-auth-azure: rolling back config: timestamp=2023-10-13T16:41:33.978-0700
2023-10-13T16:41:37.676-0700 [DEBUG] perf-sec.core0.auth.local-azure.auth_local-azure_b0e813b6.local-azure.vault-plugin-auth-azure: rolling back config: timestamp=2023-10-13T16:41:37.676-0700

After fix:

2023-10-13T16:49:20.192-0700 [DEBUG] perf-pri.core0.auth.local-azure.auth_local-azure_da705d54.local-azure.vault-plugin-auth-azure: rolling back config: timestamp=2023-10-13T16:49:20.191-0700

Azure Secrets PR: hashicorp/vault-plugin-secrets-azure#164

@fairclothjm
Copy link
Contributor

fairclothjm commented Oct 16, 2023

Thanks! Can we please add a Changelog entry?

Are we also going to make the same change for Azure secrets?

Edit: I didn't see the link to the azure secrets PR. Thanks!

CHANGELOG.md Outdated Show resolved Hide resolved
Co-authored-by: John-Michael Faircloth <fairclothjm@users.noreply.github.com>
@Zlaticanin Zlaticanin merged commit 9df3be7 into main Oct 16, 2023
4 checks passed
@Zlaticanin Zlaticanin deleted the VAULT-19950/fix-walprefix-path branch October 16, 2023 17:21
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