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

Implement proper workflow engine shutdown #5367

Conversation

khushboobhatia01
Copy link
Contributor

This pull request implements graceful workflow engine shutdown. On shutdown, we stop consuming new requests and give existing active requests some time to complete before we kill the engine.

@pull-request-size pull-request-size bot added the size/S PR that changes 10-29 lines. Very easy to review. label Sep 21, 2021
@m4dcoder m4dcoder added this to the 3.6.0 milestone Sep 21, 2021
@pull-request-size pull-request-size bot added size/L PR that changes 100-499 lines. Requires some effort to review. and removed size/S PR that changes 10-29 lines. Very easy to review. labels Sep 22, 2021
Copy link
Contributor

@m4dcoder m4dcoder left a comment

Choose a reason for hiding this comment

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

If we are implementing proper shutdown, this is not sufficient.

  1. On shutdown, the workflow engine should remove itself from the service registry.
  2. If there are other workflow engines in the service registry, then do the shutdown sequence. The shutdown sequence should be something like stop accepting incoming requests and wait until this workflow engine completed processing any requests (not some arbitrary sleep).
  3. Else if there are no other workflow engine in the service registry, then the workflow engine needs to stop accepting requests, pause all running workflow executions, and then proceed with rest of the shutdown sequence.
  4. On workflow engine startup, any workflow executions paused by the shutdown should be resumed.

@amanda11
Copy link
Contributor

amanda11 commented Oct 1, 2021

@khushboobhatia01 Have we agreed to go for a bigger fix, if so is it ok if i remove this PR from the 3.6 milestone?

@khushboobhatia01
Copy link
Contributor Author

Hi @amanda11, I think we can go ahead and remove the milestone tag. I've started working on the approach we've discussed and will close this MR.

@amanda11
Copy link
Contributor

amanda11 commented Oct 1, 2021

Hi @amanda11, I think we can go ahead and remove the milestone tag. I've started working on the approach we've discussed and will close this MR.

Thanks for update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
service: workflow engine size/L PR that changes 100-499 lines. Requires some effort to review. status:under discussion
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants