fix(zone.js): remove abort listener once fetch is settled#57882
Closed
arturovt wants to merge 1 commit intoangular:mainfrom
Closed
fix(zone.js): remove abort listener once fetch is settled#57882arturovt wants to merge 1 commit intoangular:mainfrom
abort listener once fetch is settled#57882arturovt wants to merge 1 commit intoangular:mainfrom
Conversation
54d3e58 to
938e2e1
Compare
Contributor
This commit updates the `fetch` patch for zone.js. Currently, we're attaching an `abort` event listener on the signal (when it's provided) and never removing it. We should be good citizens and remove event listeners whenever objects need to be properly collected. In Firefox, when saving a heap snapshot and running it through `fxsnapshot`, querying `AbortSignal` will print a so-called "CaptureMap" with a list of "lambdas," indicating that the signal is not garbage collected because of the event listener lambda function.
938e2e1 to
ccd6e48
Compare
AndrewKushnir
approved these changes
Oct 4, 2024
Contributor
|
Caretaker note: presubmit is "green" for this PR. |
Contributor
|
This PR was merged into the repository by commit 6976349. The changes were merged into the following branches: main, 18.2.x |
AndrewKushnir
pushed a commit
that referenced
this pull request
Oct 7, 2024
This commit updates the `fetch` patch for zone.js. Currently, we're attaching an `abort` event listener on the signal (when it's provided) and never removing it. We should be good citizens and remove event listeners whenever objects need to be properly collected. In Firefox, when saving a heap snapshot and running it through `fxsnapshot`, querying `AbortSignal` will print a so-called "CaptureMap" with a list of "lambdas," indicating that the signal is not garbage collected because of the event listener lambda function. PR Close #57882
This was referenced Oct 11, 2024
Open
Open
Open
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This commit updates the
fetchpatch for zone.js. Currently, we're attaching anabortevent listener on the signal (when it's provided) and never removing it. We should be good citizens and remove event listeners whenever objects need to be properly collected. In Firefox, when saving a heap snapshot and running it throughfxsnapshot, queryingAbortSignalwill print a so-called "CaptureMap" with a list of "lambdas," indicating that the signal is not garbage collected because of the event listener lambda function.