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

Breaking changes coming to Adapters' use of custom sessions #1040

Open
briantist opened this issue Sep 2, 2023 · 0 comments
Open

Breaking changes coming to Adapters' use of custom sessions #1040

briantist opened this issue Sep 2, 2023 · 0 comments
Assignees
Labels
adapters related to the Adapter system announcement Announces some change or future change to be aware of breaking-change
Milestone

Comments

@briantist
Copy link
Contributor

briantist commented Sep 2, 2023

Background

The Adapter system in Vault wraps HTTP calls, and by default handles creation of the Session object. As a result, Adapters accept some options for customizing how the session is created:

  • verify
  • cert
  • proxies

Adapters also support passing in a session you've created on your own, allowing complete customization of the session object.

Problem

Because of the way we store some of the Adapter session options, and use them later in making requests, it's possible that if you created a session yourself, some of the options you chose in the session might be overridden by the option values set in the Adapter. This happens even if you didn't use the Adapter options and left them at their defaults. More info:

What's changing

Ideally, if you passed a session into the adapter, we shouldn't be touching it: we trust that you created the session exactly as you wanted it to be. But this is an abrupt change and would lead to some unexpected changes around things like verifying certificates.

As a result, we're going to make a series of smaller breaking changes, starting with us inspecting a passed in session, and only allowing overriding of its properties if those things aren't set in the session:

In the next major version after that, we'll look to remove that middle ground, and when a session object is passed in, we will ignore the other options completely and only use your passed in session.

Schedule

As of right now, the schedule looks like this:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
adapters related to the Adapter system announcement Announces some change or future change to be aware of breaking-change
Projects
None yet
Development

No branches or pull requests

1 participant