-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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 BaseSecretsBackend.build_path generic #7948
Conversation
Currently the arguments required for it are `connections_prefix` and `conn_id` . Changing this to `path_prefix` and `secret_id` allows using that method for retrieving variables too
@@ -150,7 +150,7 @@ def get_conn_uri(self, conn_id: str) -> Optional[str]: | |||
:param conn_id: connection id | |||
:type conn_id: str | |||
""" | |||
secret_path = self.build_path(connections_prefix=self.connections_path, conn_id=conn_id) | |||
secret_path = self.build_path(self.connections_path, conn_id) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
secret_path = self.build_path(self.connections_path, conn_id) | |
secret_path = "/".join([self.connections_path, conn_id]) |
Do we need this method at all? This can be expressed with one line of code and will be more generic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is a separate method for SecretsBackend Meta class so that each Backend can implement it as they all have a separate and all have a prefix and a path.
Currently the arguments required for it are `connections_prefix` and `conn_id` . Changing this to `path_prefix` and `secret_id` allows using that method for retrieving variables too (cherry picked from commit eb4af4f)
Currently the arguments required for it are `connections_prefix` and `conn_id` . Changing this to `path_prefix` and `secret_id` allows using that method for retrieving variables too (cherry picked from commit eb4af4f)
Currently the arguments required for it are `connections_prefix` and `conn_id` . Changing this to `path_prefix` and `secret_id` allows using that method for retrieving variables too (cherry picked from commit eb4af4f)
Currently the arguments required for it are `connections_prefix` and `conn_id` . Changing this to `path_prefix` and `secret_id` allows using that method for retrieving variables too (cherry picked from commit eb4af4f)
Currently the arguments required for it are
connections_prefix
andconn_id
. Changing this topath_prefix
andsecret_id
allows using that method for retrieving variables tooIssue link: WILL BE INSERTED BY boring-cyborg
Make sure to mark the boxes below before creating PR: [x]
In case of fundamental code change, Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in UPDATING.md.
Read the Pull Request Guidelines for more information.