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

Feature/rds docdb fix #145

Merged
merged 5 commits into from
Apr 23, 2023

Conversation

tarunmenon95
Copy link
Contributor

Fixed bug where calling any RDS cluster function would include docdb resource's if they were present. As such docdb snapshots would be created and removed if any RDS cluster actions were invoked.

Example of issue:

  1. For this example we have a stack with both a docdb and rds_cluster resource. No snapshots have been created yet for either.
    Screen Shot 2023-04-21 at 3 33 13 pm

  2. We call shelvery create_backups rds_cluster

  3. We can observe in the logs immediately that shelvery has picked up the docdb_cluster as a resource to backup alongside our actual rds cluster.
    Screen Shot 2023-04-21 at 3 35 26 pm

  4. Shelvery creates a snapshot of the doc db cluster aswell as a snapshot for the actual RDS cluster.
    Screen Shot 2023-04-21 at 3 35 35 pm
    Screen Shot 2023-04-21 at 3 38 34 pm

Example of fix:

The solution was to remove any clusters from the list of clusters returned which had Engine='docdb'

  1. With the same resources as before with no snapshots existing.
  2. We call shelvery create_backups rds_cluster
  3. This time we observe that only 1 cluster resource is picked up which is our actual RDS cluster as expected. DocDB is omitted as expected.
    Screen Shot 2023-04-21 at 3 41 10 pm
  4. Observe no DocDB snapshot is created
    Screen Shot 2023-04-21 at 3 41 29 pm
  5. RDS Cluster snapshot is created as expected
    Screen Shot 2023-04-21 at 3 41 40 pm

@Guslington Guslington merged commit 256fbd3 into base2Services:develop Apr 23, 2023
0 of 2 checks passed
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.

None yet

2 participants