Call FinishRequest for ResponseCallback on timeout of fetch event
Previously ResponseCallback was not discarded even if the waitUntil() hits the timeout. This ends up with keeping a request stored in `ServiceWorkerVersion::inflight_requests_` until respondWith() is settled even if the waitUntil() hits the timeout. This CL changes the behavior by closing the Mojo endpoint for ResponseCallback on timeout. In addition, another bug was revealed by the fix where `is_endpoint_ready_` was not updated correctly. This caused an issue of dispatching a fetch event while it's still in stopping state. This CL updates the flag in OnStopping() which is called synchronously from EmbeddedWorkerInstance::Stop(). Bug: 1156091, 1156081, 1156626, 1152793 Change-Id: Iaa227b0dbfa7cd6046e441a1c73c18e15757172a Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2586645Reviewed-by:Matt Falkenhagen <falken@chromium.org> Reviewed-by:
Asami Doi <asamidoi@chromium.org> Commit-Queue: Makoto Shimazu <shimazu@chromium.org> Cr-Commit-Position: refs/heads/master@{#838601}
Showing
Please register or sign in to comment