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

fix: Drain event emitter even when feature fails to initialize #730

Merged
merged 1 commit into from
Sep 25, 2023

Conversation

metal-messiah
Copy link
Member

@metal-messiah metal-messiah commented Sep 22, 2023

A failure to import and initialize a feature could block the agent from draining data out of the event emitter, which prevents the agent from making any successful calls. This fix allows the event emitter to drain even when an individual feature fails to initialize.

Overview

A failure to import and initialize a feature could block the agent from draining data out of the event emitter, which prevents the agent from making any successful calls. This fix allows the event emitter to drain even when an individual feature fails to initialize. This is also tangentially related to the Session Replay feature failing to import and blocking the agent on polyfill builds.

Related Issue(s)

This PR would replace the need for #729 if deemed appropriate

Testing

All tests should continue passing

@github-actions
Copy link

Asset Size Report

Merging this pull request will result in the following asset size changes:

Agent Asset Previous Size New Size Diff
lite loader 29.25 kB / 10.11 kB (gzip) 29.3 kB / 10.12 kB (gzip) 0.16% / 0.06% (gzip)
lite async-chunk 45.5 kB / 15.09 kB (gzip) 45.5 kB / 15.09 kB (gzip) 0% / 0% (gzip)
pro loader 46.66 kB / 15.59 kB (gzip) 46.7 kB / 15.6 kB (gzip) 0.1% / 0.03% (gzip)
pro async-chunk 166.12 kB / 52.32 kB (gzip) 166.12 kB / 52.32 kB (gzip) 0% / 0% (gzip)
spa loader 53.07 kB / 17.56 kB (gzip) 53.12 kB / 17.56 kB (gzip) 0.09% / 0.03% (gzip)
spa async-chunk 166.12 kB / 52.32 kB (gzip) 166.12 kB / 52.32 kB (gzip) 0% / 0% (gzip)
lite-polyfills loader 99.76 kB / 31.77 kB (gzip) 99.8 kB / 31.77 kB (gzip) 0.04% / 0% (gzip)
lite-polyfills async-chunk 57.93 kB / 17.3 kB (gzip) 57.93 kB / 17.3 kB (gzip) 0% / 0% (gzip)
pro-polyfills loader 119.74 kB / 37.75 kB (gzip) 119.78 kB / 37.76 kB (gzip) 0.03% / 0.01% (gzip)
pro-polyfills async-chunk 99.06 kB / 26.76 kB (gzip) 99.06 kB / 26.76 kB (gzip) 0% / 0% (gzip)
spa-polyfills loader 127.72 kB / 39.89 kB (gzip) 127.76 kB / 39.89 kB (gzip) 0.03% / 0% (gzip)
spa-polyfills async-chunk 113.94 kB / 31.15 kB (gzip) 113.94 kB / 31.15 kB (gzip) 0% / 0% (gzip)
worker loader 41.36 kB / 13.99 kB (gzip) 41.41 kB / 14 kB (gzip) 0.11% / 0.03% (gzip)
worker async-chunk 45.56 kB / 15.44 kB (gzip) 45.56 kB / 15.44 kB (gzip) 0% / 0% (gzip)

@codecov
Copy link

codecov bot commented Sep 22, 2023

Codecov Report

Merging #730 (54053b4) into main (ba4dc99) will increase coverage by 0.05%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #730      +/-   ##
==========================================
+ Coverage   86.78%   86.83%   +0.05%     
==========================================
  Files         135      135              
  Lines        5318     5319       +1     
  Branches      734      734              
==========================================
+ Hits         4615     4619       +4     
+ Misses        640      637       -3     
  Partials       63       63              
Flag Coverage Δ
integration-tests 87.15% <100.00%> (+0.08%) ⬆️
unit-tests 79.33% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
src/features/utils/instrument-base.js 94.52% <100.00%> (+0.07%) ⬆️

... and 1 file with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@github-actions
Copy link

github-actions bot commented Sep 23, 2023

Static Badge

Last ran on September 23, 2023 10:49:47 CDT
Checking merge of (54053b4) into main (ba4dc99)

@metal-messiah metal-messiah merged commit 06edda5 into main Sep 25, 2023
@metal-messiah metal-messiah deleted the sr-polyfill-fix branch September 25, 2023 17:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants