Skip to content

[prism] Add an idle shutdown timout to prism binary.#32276

Merged
lostluck merged 2 commits intoapache:masterfrom
lostluck:prismIdle
Aug 22, 2024
Merged

[prism] Add an idle shutdown timout to prism binary.#32276
lostluck merged 2 commits intoapache:masterfrom
lostluck:prismIdle

Conversation

@lostluck
Copy link
Copy Markdown
Contributor

Adding a flag --idle_shutdown_timeout to avoid SDKs leaving dangling prism processes after a job terminates.

  • Operates simply: Tracks the number of terminations, and compares to the number of started jobs. If they're equal, then start the idle timer.
  • Timer is cleared if there's a new job.
  • Initial timer set on start of prism process.
  • Currently only actively running jobs extend the timeout, and other actions (eg. via Job management) do not extend the timeout.
  • Negative durations do not idle shutdown.

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Mention the appropriate issue in your description (for example: addresses #123), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, comment fixes #<ISSUE NUMBER> instead.
  • Update CHANGES.md with noteworthy changes.
  • If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.

To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md

GitHub Actions Tests Status (on master branch)

Build python source distribution and wheels
Python tests
Java tests
Go tests

See CI.md for more information about GitHub Actions CI or the workflows README to see a list of phrases to trigger workflows.

@lostluck lostluck requested a review from damondouglas August 21, 2024 23:32
@lostluck lostluck requested review from jrmccluskey and removed request for damondouglas August 22, 2024 00:06
@lostluck
Copy link
Copy Markdown
Contributor Author

R: @jrmccluskey

@lostluck lostluck added this to the 2.59.0 Release milestone Aug 22, 2024
@lostluck
Copy link
Copy Markdown
Contributor Author

This will end up being cherry picked into the release, along with an associated change to use them with the Java and Python runner wrappers.

@github-actions
Copy link
Copy Markdown
Contributor

Stopping reviewer notifications for this pull request: review requested by someone other than the bot, ceding control. If you'd like to restart, comment assign set of reviewers

Copy link
Copy Markdown
Contributor

@jrmccluskey jrmccluskey left a comment

Choose a reason for hiding this comment

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

LGTM, one docstring change

Co-authored-by: Jack McCluskey <34928439+jrmccluskey@users.noreply.github.com>
@lostluck
Copy link
Copy Markdown
Contributor Author

Thank you very much!

@lostluck lostluck merged commit 995724d into apache:master Aug 22, 2024
@lostluck lostluck deleted the prismIdle branch August 22, 2024 14:31
lostluck added a commit that referenced this pull request Aug 22, 2024
* Add an idle shutdown timout to prism binary.

* Correct flag text.

Co-authored-by: Jack McCluskey <34928439+jrmccluskey@users.noreply.github.com>

---------

Co-authored-by: lostluck <13907733+lostluck@users.noreply.github.com>
Co-authored-by: Jack McCluskey <34928439+jrmccluskey@users.noreply.github.com>
reeba212 pushed a commit to reeba212/beam that referenced this pull request Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants