-
Notifications
You must be signed in to change notification settings - Fork 363
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
Clean up degenerate deployments #3538
Clean up degenerate deployments #3538
Conversation
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.
As far as I could see the DEGENERATE
state will not appear anymore.
Actually it should have never been introduced, so it's good that we clean it up now.
Initially the DEGENERATE
state was meant for deployments, which were "half way created" because the process was not created in one transaction together with the deployment. But this has been fixed already.
So apps using deployments, be it a new app or a running app, will always have a process guid already, which makes this state obsolete.
A small test for the migration, which creates a few deployments with state DEGENERATE
and checks that the migration deletes them would be nice, because we get early feedback whether the migration runs on all supported DBs.
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.
LGTM
@svkrieger & @WeiQuan0605 - curious on your testing if you ran into this. In prod today we migrated from The migration script when it fires runs into the following error:
We have over This appears to be deleting the parent record but not the child records since a "cascade" delete is not taking place. Can you advise on your testing why you did not get the errors ? For reference we are using Postgres 12.14 on Amazon RDS Thanks |
@ChrisMcGowan Looks like something we missed 😞 |
Thank you @johha |
Signed-off-by: João Pereira <[email protected]>
With the fix, job finalized-degenerate-deployment only considers active deployments.
status.reason
will not haveDEGENERATE
anymore. The oldDEGENERATE
records should be cleaned up through DB migration.I have reviewed the contributing guide
I have viewed, signed, and submitted the Contributor License Agreement
I have made this pull request to the
main
branchI have run all the unit tests using
bundle exec rake
I have run CF Acceptance Tests