add the ability to pause/buffer IConfigurationRegistry event and adopt in extension service #138259
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.
Profiling has shown that reading contribution points updates configurations a lot 1. The event of the configuration registry fire in my dev setup around 50 times. There is only 4 listeners to these events but assuming a listener takes 1ms it still makes 200ms (
50*4*1) to fire them.This PR adds a way to pause/resume eventing of the configuration registry and adopts that in the extension service when reading contribution points.
I measured the gains against todays insiders and things are looking pretty good. I have tested with only builtin extensions and with the 30 extensions that I have installed (using my data as real world representative, it is also pretty close to the real world average duration for this). The measurements are the times between the
willHandleExtensionPointsanddidHandleExtensionPointsperf-marks (F1 > Startup Performance)0cc0904c56)7907361sandy081/perfc4bd3f8--
1 Looks like most events are triggered from custom editors and notebooks. Something to drill into further