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

Erv2: Implement resource reconciliation dependencies #4785

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

lechuk47
Copy link
Contributor

@lechuk47 lechuk47 commented Dec 2, 2024

This PR implements resource reconciliation dependencies.

The main use case for now is RDS read replicas. Every time a Primary is reconciled, it will trigger a reconciliation for its read replicas. This is needed to sync the credentials output secrets in case a password reset is requested.

except ExternalResourceValidationError as e:
self.errors[key] = e
continue

reconciliation = Reconciliation(
key=key,
resource_hash=resource.hash(),
input=self._serialize_resource_input(resource),
input=resource.json(),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like _serialize_resource_input isn't in use anymore. Please remove it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's already removed.

def find_linked_resources(
self, spec: ExternalResourceSpec
) -> set[ExternalResourceKey]:
return set()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a doc string here, mainly because it's the base class.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added.

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