-
Notifications
You must be signed in to change notification settings - Fork 487
feat: declared background workers + frankenphp_get_worker_handle() #2617
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
Open
nicolas-grekas
wants to merge
37
commits into
php:main
Choose a base branch
from
nicolas-grekas:bgworker-server
base: main
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.
Open
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
936f791
fix: a thread that ended on its own can still be asked to shut down
nicolas-grekas 9cff092
feat: declared background workers + frankenphp_get_worker_handle()
nicolas-grekas bae8218
fix: a blocking receive on the handle marks a background worker ready
nicolas-grekas 0d81c76
fix: never inherit the reserved worker variables
nicolas-grekas 584a512
fix: cap the restart backoff, and EOF a handle a forked child still h…
nicolas-grekas bd359b7
fix: resolve max_threads auto on the HTTP budget
nicolas-grekas bd72155
chore: simplifications and wording from the review
nicolas-grekas 7613458
test: cover the parked run and the handle cache
nicolas-grekas 19c4510
docs: flag frankenphp_get_worker_handle() experimental in the stub
nicolas-grekas d51dc26
feat: frankenphp_worker_tick(), the explicit ready point of backgroun…
nicolas-grekas 9bac067
feat: FRANKENPHP_WORKER_BACKGROUND holds the name, HTTP workers untou…
nicolas-grekas c798593
feat: wake a background worker once at start
nicolas-grekas a90f83b
docs: event loop example for background workers
nicolas-grekas 372ad78
refactor: one lifecycle abstraction instead of two
nicolas-grekas 873c353
fix: never block or race on the startup failure channel
nicolas-grekas f326169
feat: max_execution_time bounds the bootstrap of a background worker
nicolas-grekas 402d164
docs: stop the whole loop on drain in the Revolt example
nicolas-grekas a6883d6
test: only assert the bounded bootstrap where the timers are known to…
nicolas-grekas 9f1770a
feat: num defaults to one thread for background workers
nicolas-grekas eea5f34
chore: review polish
nicolas-grekas b7d7ab3
test: the tick leaves the handle quiet
nicolas-grekas 647f3e0
fix: keep generating unique names for workers that share a script
nicolas-grekas 6385231
feat: report the server of a worker as its own metric label
nicolas-grekas 0685854
fix: address the review of the background worker lifecycle
alexandre-daubois d8a6e31
fix: keep the declared path as the default worker name
nicolas-grekas 31234a0
fix: pace only the background runs that end too fast
nicolas-grekas 06ee910
refactor: declare the labels of a worker instead of widening the metrics
nicolas-grekas d7729c7
feat: report the server of a worker through an optional ServerMetrics…
alexandre-daubois 12fa36a
feat: the handle of a background worker becomes an object
nicolas-grekas 3c5c48c
refactor: keep the stream of a handle on the handle, not on the thread
nicolas-grekas e611798
docs: lead with the poll loop, the stream is for the libraries that t…
nicolas-grekas 386a888
fix: a handle built behind the constructor must not reach the Go side
nicolas-grekas fbb0b02
fix: pace a crash loop whatever the run lasted
nicolas-grekas 0d81bd8
chore: check the server the same way in SendRequest and SendMessage
nicolas-grekas 2da5ffa
fix: form the Windows socket pair on loopback, and only with ourselves
nicolas-grekas 3c66d02
feat: bound the wait for a background worker to become ready
nicolas-grekas 6c9a8c9
chore: fewer comments, the ones left say why
nicolas-grekas File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.