-
Notifications
You must be signed in to change notification settings - Fork 43
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
Refactor deployments storage on redeploy and undeployment #483
Conversation
Hi @ariefrahmansyah, I will have another look at this PR today. In the meantime, I was thinking it may also be good to capture the data migration steps (the SQL script and any ad-hoc action that needs to be taken for deployments since Merlin 0.34.0) in this MR as a |
Hi Krithika, I'm still playing on the SQL on my local machine. Will update the MR with the SQL doc. Btw, I'll create the doc with this path: |
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.
@ariefrahmansyah left some comments. As discussed earlier, do capture the data migration script in this PR as well. I think it should be safe to add it as a normal SQL migration file as we don't anticipate any ad-hoc handling for the deployments status update. Thanks!
* Remove console.log * Make terminated's EuiHealth color to default
* Improve current deployment label logic
* Set pending deployment to terminated too
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.
@ariefrahmansyah Left some more comments. One the whole, LGTM. Will have another look when the open comments are resolved, as some of them may require some thought. Thanks!
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.
Left one comment. The rest LGTM. Thanks, @ariefrahmansyah !
What this PR does / why we need it:
The terminated endpoint means the user has triggered Undeployment and there's no deployed endpoint in the cluster. When we redeploy this terminated endpoint, the deployment history should show all previous successful deployment logs as Not Deployed and the new deployment as Pending.
However, when redeploying the terminated endpoint, the deployment history shows the previous successful deployment as the current and deployed one:
Before redeployment of terminated endpoint:
Actual view from redeployment of terminated endpoint:
Fixes introduced by this PR:
Before redeployment, the current label is given to the latest successful/terminated endpoint:
During redeployment:
After redeployment succeed:
*Note: Please ignore the time displayed as
in 7 hours
-- this is because I'm running from local and the time zone is not translated correctly.Behind the scene, we refactor deployments table for given version endpoint for redeployment and unemployment:
a. new deployment status = running/serving,
b. old successful deployment status = terminated
a. old successful deployment status = terminated
Which issue(s) this PR fixes:
Does this PR introduce a user-facing change?:
Checklist