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: SPA feature respects ajax deny_list for fetch #633

Merged
merged 1 commit into from
Aug 2, 2023

Conversation

patrickhousley
Copy link
Contributor

The SPA feature will now properly respect the ajax deny list and block internal settings for fetch calls. In prior versions, the SPA feature only consulted the ajax deny list for XMLHttpRequest calls.

Overview

The SPA feature will now properly respect the ajax deny list and block internal settings for fetch calls. In prior versions, the SPA feature only consulted the ajax deny list for XMLHttpRequest calls.

Related Issue(s)

https://issues.newrelic.com/browse/NR-146248

Testing

Build the agent and run the local server. The below links can be used to test the functionality.

Block Internal Disabled
Block Internal Enabled

@codecov
Copy link

codecov bot commented Aug 2, 2023

Codecov Report

Merging #633 (1d016fa) into main (27a1b04) will not change coverage.
Report is 1 commits behind head on main.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main     #633   +/-   ##
=======================================
  Coverage   68.06%   68.06%           
=======================================
  Files         130      130           
  Lines        6018     6018           
  Branches     1142     1142           
=======================================
  Hits         4096     4096           
  Misses       1578     1578           
  Partials      344      344           
Flag Coverage Δ
integration-tests 83.42% <100.00%> (ø)
jest-component 21.19% <0.00%> (ø)
jest-unit 23.11% <0.00%> (ø)

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

Files Changed Coverage Δ
src/features/spa/aggregate/index.js 50.68% <100.00%> (ø)

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

@github-actions
Copy link

github-actions bot commented Aug 2, 2023

Asset Size Report

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

Asset Name Previous Size New Size Diff
nr-loader-spa.min 51.2 kB / 17.2 kB (gzip) 51.2 kB / 17.2 kB (gzip) -0% / +0.01% (gzip)
nr-loader-full.min 44.76 kB / 15.26 kB (gzip) 44.76 kB / 15.26 kB (gzip) -0% / -0.01% (gzip)
nr-loader-rum.min 28 kB / 9.99 kB (gzip) 28 kB / 9.99 kB (gzip) -0% / +0.01% (gzip)
nr-loader-spa-polyfills.min 125.56 kB / 39.67 kB (gzip) 125.56 kB / 39.67 kB (gzip) -0% / +0% (gzip)
nr-loader-full-polyfills.min 117.55 kB / 37.52 kB (gzip) 117.55 kB / 37.52 kB (gzip) -0% / -0% (gzip)
nr-loader-rum-polyfills.min 97.54 kB / 31.76 kB (gzip) 97.54 kB / 31.76 kB (gzip) -0% / -0% (gzip)
nr-loader-worker.min 41.32 kB / 13.98 kB (gzip) 41.32 kB / 13.98 kB (gzip) -0% / -0% (gzip)

Merging this pull request will result in the following NPM package consumer size changes:

Asset Name Previous Size New Size Diff
Browser Agent 51.33 kB / 17.1 kB (gzip) 51.33 kB / 17.1 kB (gzip) -0% / -0% (gzip)
Custom Lite Agent 28.14 kB / 9.92 kB (gzip) 28.14 kB / 9.92 kB (gzip) -0% / -0% (gzip)
Custom Pro Agent 44.81 kB / 15.09 kB (gzip) 44.81 kB / 15.09 kB (gzip) -0% / -0% (gzip)
Custom SPA Agent 51.21 kB / 17.06 kB (gzip) 51.21 kB / 17.06 kB (gzip) -0% / -0% (gzip)
Worker Agent 305.17 kB / 94.37 kB (gzip) 305.2 kB / 94.37 kB (gzip) +0.01% / +0% (gzip)
Other Standard CDN Assets

Released Assets

Asset Name Asset Size
recorder.643cfeda.min.js 166.33 kB / 52.44 kB (gzip)
spa-aggregate.495db083.min.js 20.96 kB / 7.45 kB (gzip)
page_view_timing-aggregate.d72a908a.min.js 14.99 kB / 5.44 kB (gzip)
860.8fec16f2.min.js 14.09 kB / 5.27 kB (gzip)
session_trace-aggregate.a490ad60.min.js 12.25 kB / 4.53 kB (gzip)
page_view_event-aggregate.e765729e.min.js 11.12 kB / 4.19 kB (gzip)
jserrors-aggregate.f8100d3b.min.js 9.55 kB / 3.65 kB (gzip)
metrics-aggregate.41a8a1b8.min.js 8.83 kB / 3 kB (gzip)
646.5aafce46.min.js 7.99 kB / 3.36 kB (gzip)
session_replay-aggregate.948ed12b.min.js 7.97 kB / 2.93 kB (gzip)
ajax-aggregate.629e6d59.min.js 7.19 kB / 3.1 kB (gzip)
compressor.772ac1fe.min.js 7.09 kB / 3.57 kB (gzip)
page_action-aggregate.636893b0.min.js 4.73 kB / 1.92 kB (gzip)
async-api.eaff3276.min.js 2.69 kB / 1.38 kB (gzip)
session-manager.22036a2b.min.js 1.47 kB / 742 B (gzip)
lazy-feature-loader.d2774909.min.js 1.17 kB / 498 B (gzip)

Built Assets

Asset Name Asset Size
recorder.643cfeda.min.js 166.33 kB / 52.44 kB (gzip)
spa-aggregate.ca6a8575.min.js 20.98 kB / 7.45 kB (gzip)
page_view_timing-aggregate.d72a908a.min.js 14.99 kB / 5.44 kB (gzip)
860.8fec16f2.min.js 14.09 kB / 5.27 kB (gzip)
session_trace-aggregate.a490ad60.min.js 12.25 kB / 4.53 kB (gzip)
page_view_event-aggregate.e765729e.min.js 11.12 kB / 4.19 kB (gzip)
jserrors-aggregate.f8100d3b.min.js 9.55 kB / 3.65 kB (gzip)
metrics-aggregate.41a8a1b8.min.js 8.83 kB / 3 kB (gzip)
646.5aafce46.min.js 7.99 kB / 3.36 kB (gzip)
session_replay-aggregate.948ed12b.min.js 7.97 kB / 2.93 kB (gzip)
ajax-aggregate.629e6d59.min.js 7.19 kB / 3.1 kB (gzip)
compressor.772ac1fe.min.js 7.09 kB / 3.57 kB (gzip)
page_action-aggregate.636893b0.min.js 4.73 kB / 1.92 kB (gzip)
async-api.eaff3276.min.js 2.69 kB / 1.38 kB (gzip)
session-manager.22036a2b.min.js 1.47 kB / 742 B (gzip)
lazy-feature-loader.d2774909.min.js 1.17 kB / 498 B (gzip)
Other Polyfill CDN Assets

Released Assets

Asset Name Asset Size
recorder.643cfeda-es5.min.js 167.03 kB / 52.48 kB (gzip)
nr-polyfills.min.js 52.26 kB / 18.01 kB (gzip)
session_trace-aggregate.55fac0dd-es5.min.js 32.27 kB / 8.5 kB (gzip)
compressor.5b9c7398-es5.min.js 30.02 kB / 11.29 kB (gzip)
session_replay-aggregate.6c0aba07-es5.min.js 19.27 kB / 6.54 kB (gzip)
page_view_timing-aggregate.3d86db09-es5.min.js 18.68 kB / 6.17 kB (gzip)
spa-aggregate.1f73f06f-es5.min.js 17.77 kB / 6.14 kB (gzip)
173.3788d9f7-es5.min.js 17.41 kB / 6.14 kB (gzip)
page_view_event-aggregate.e71662d2-es5.min.js 12.65 kB / 4.8 kB (gzip)
jserrors-aggregate.2883be04-es5.min.js 12.33 kB / 4.4 kB (gzip)
385.d801f3b5-es5.min.js 10.49 kB / 4.18 kB (gzip)
metrics-aggregate.1471998c-es5.min.js 10.18 kB / 3.41 kB (gzip)
945.d2c7843e-es5.min.js 7.51 kB / 2.72 kB (gzip)
page_action-aggregate.087bc19b-es5.min.js 7.33 kB / 2.64 kB (gzip)
ajax-aggregate.d44e21ef-es5.min.js 4.35 kB / 2.07 kB (gzip)
async-api.bb0e3099-es5.min.js 3.84 kB / 1.89 kB (gzip)
session-manager.618cfdd6-es5.min.js 1.7 kB / 783 B (gzip)
lazy-feature-loader.c4f55624-es5.min.js 1.22 kB / 514 B (gzip)

Built Assets

Asset Name Asset Size
recorder.643cfeda-es5.min.js 167.03 kB / 52.48 kB (gzip)
nr-polyfills.min.js 52.26 kB / 18.01 kB (gzip)
session_trace-aggregate.55fac0dd-es5.min.js 32.27 kB / 8.5 kB (gzip)
compressor.5b9c7398-es5.min.js 30.02 kB / 11.29 kB (gzip)
session_replay-aggregate.6c0aba07-es5.min.js 19.27 kB / 6.54 kB (gzip)
page_view_timing-aggregate.3d86db09-es5.min.js 18.68 kB / 6.17 kB (gzip)
spa-aggregate.d4d77176-es5.min.js 17.8 kB / 6.14 kB (gzip)
173.3788d9f7-es5.min.js 17.41 kB / 6.14 kB (gzip)
page_view_event-aggregate.e71662d2-es5.min.js 12.65 kB / 4.8 kB (gzip)
jserrors-aggregate.2883be04-es5.min.js 12.33 kB / 4.4 kB (gzip)
385.d801f3b5-es5.min.js 10.49 kB / 4.18 kB (gzip)
metrics-aggregate.1471998c-es5.min.js 10.18 kB / 3.41 kB (gzip)
945.d2c7843e-es5.min.js 7.51 kB / 2.72 kB (gzip)
page_action-aggregate.087bc19b-es5.min.js 7.33 kB / 2.64 kB (gzip)
ajax-aggregate.d44e21ef-es5.min.js 4.35 kB / 2.07 kB (gzip)
async-api.bb0e3099-es5.min.js 3.84 kB / 1.89 kB (gzip)
session-manager.618cfdd6-es5.min.js 1.7 kB / 783 B (gzip)
lazy-feature-loader.c4f55624-es5.min.js 1.22 kB / 514 B (gzip)

@github-actions
Copy link

github-actions bot commented Aug 2, 2023

Static Badge

Last ran on August 02, 2023 13:44:03 CDT
Checking merge of (1d016fa) into main (27a1b04)

@patrickhousley patrickhousley merged commit ccfe510 into main Aug 2, 2023
@patrickhousley patrickhousley deleted the fix-spa-denylist branch August 2, 2023 19:24
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