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 AbortSignal.timeout #32622

Merged
merged 1 commit into from
Feb 2, 2022

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

@chromium-wpt-export-bot chromium-wpt-export-bot commented Jan 31, 2022

AbortSignal.timeout is a static method that creates a new AbortSignal
that is automatically aborted after a specified duration. The
implementation is essentially PostDelayedTask(SignalAbort, ms).

Throttling: this API is specced to use the timer task source, but there
are three internally due to our throttling implementation. We use
immediate for the timeout == 0 case and high nesting for timeount > 0
(the typical case), i.e. all non-zero timeouts are eligible for
throttling (Note: this matches scheduler.postTask()).

Spec PR: whatwg/dom#1032
I2P: https://groups.google.com/a/chromium.org/g/blink-dev/c/9Y290P1WimY/m/bru989iAAgAJ

Bug: 1181925
Change-Id: I192d82a8bf12c368abcd47ae6c50e80f50654cf9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3425124
Reviewed-by: Domenic Denicola <domenic@chromium.org>
Reviewed-by: Mason Freed <masonf@chromium.org>
Commit-Queue: Scott Haseley <shaseley@chromium.org>
Cr-Commit-Position: refs/heads/main@{#966406}

Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

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

The review process for this patch is being conducted in the Chromium project.

@chromium-wpt-export-bot chromium-wpt-export-bot force-pushed the chromium-export-cl-3425124 branch 5 times, most recently from 3eb5a31 to 7b54a1a Compare February 2, 2022 19:51
AbortSignal.timeout is a static method that creates a new AbortSignal
that is automatically aborted after a specified duration. The
implementation is essentially PostDelayedTask(SignalAbort, ms).

Throttling: this API is specced to use the timer task source, but there
are three internally due to our throttling implementation. We use
immediate for the timeout == 0 case and high nesting for timeount > 0
(the typical case), i.e. all non-zero timeouts are eligible for
throttling (Note: this matches scheduler.postTask()).

Spec PR: whatwg/dom#1032
I2P: https://groups.google.com/a/chromium.org/g/blink-dev/c/9Y290P1WimY/m/bru989iAAgAJ

Bug: 1181925
Change-Id: I192d82a8bf12c368abcd47ae6c50e80f50654cf9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3425124
Reviewed-by: Domenic Denicola <domenic@chromium.org>
Reviewed-by: Mason Freed <masonf@chromium.org>
Commit-Queue: Scott Haseley <shaseley@chromium.org>
Cr-Commit-Position: refs/heads/main@{#966406}
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.

3 participants