Skip to content
This repository has been archived by the owner on Dec 13, 2023. It is now read-only.

[Feature] Support to specify shutdown grace period time for worker #2631

Merged
merged 2 commits into from
Dec 20, 2021

Conversation

hankquan
Copy link
Contributor

@hankquan hankquan commented Dec 8, 2021

Pull Request type

  • Bugfix
  • Feature
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Other (please describe):

Changes in this PR

Add a new parameter 'shutdownGracePeriodSeconds' to TaskRunnerConfigurer which is the timeout of terminating worker thread pool. Default value is 10 seconds, and can't be changed.
A task may cost longer, so it is better to make users can specify the timeout.
Default value is still 10 seconds with this new feature.

Concern:
I have removed shutdown() method from TaskPollExecutor, it is a default method, and not used by anywhere in this project, I can't see any reason to keep it, please correct me if there is potential problems, thanks.

Alternatives considered

Copy link
Collaborator

@aravindanr aravindanr left a comment

Choose a reason for hiding this comment

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

@howaric Thanks for the pull request. Could you also update the documentation in the docs folder? https://netflix.github.io/conductor/gettingstarted/client/#taskrunnerconfigurer

@aravindanr aravindanr merged commit a3001ee into Netflix:main Dec 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants