-
Notifications
You must be signed in to change notification settings - Fork 212
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
(DO NOT MERGE) Add cometbft service cancellable context #2496
Draft
fridrik01
wants to merge
26
commits into
engine-api-retry
Choose a base branch
from
add-cometbft-service-cancellable-context
base: engine-api-retry
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
(DO NOT MERGE) Add cometbft service cancellable context #2496
fridrik01
wants to merge
26
commits into
engine-api-retry
from
add-cometbft-service-cancellable-context
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
451ffef
to
c417507
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## engine-api-retry #2496 +/- ##
====================================================
- Coverage 32.20% 32.10% -0.11%
====================================================
Files 350 350
Lines 15665 15714 +49
Branches 20 20
====================================================
Hits 5045 5045
- Misses 10257 10306 +49
Partials 363 363
|
c417507
to
7062906
Compare
7062906
to
992a862
Compare
…ync-force-startup-fcu
…/beacon-kit into engine-api-retry
992a862
to
31fde13
Compare
5e45224
to
4687f00
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently, beacond hangs on SIGTERM if its inside a retry timeout. This is because the context used in the retry is not cancelled in our signal hander.
To address this, this PR adds a cancellable context to the
cometbft
service which it inherits from the context passed in toStart()
. Now, when signal handler catches a signal it will call Stop() on the service which in turn cancels the context. This causes us to properly handle signal cancellation in the retry timeout.HOWEVER, it seems that comet does not support cancellation, as I always get a panic from comet during shutdown: