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

[FEATURE REQUEST] Ability to stop requests being tracked for array of domains #1446

Closed
elliotleelewis opened this issue Dec 16, 2020 · 3 comments
Milestone

Comments

@elliotleelewis
Copy link

elliotleelewis commented Dec 16, 2020

Is your feature request related to a problem? Please describe.
We use feature flags in our SPA and the feature flag's service that we use polls for changes to these feature flags every 30 seconds. This is cluttering up our dependency logs because they're all filled with these polling requests.

Describe the solution you'd like
It would be nice to be able to stop these from being sent by filtering out their domain, so that our dependency logs are only filled with our internal application calls. Something like this in the config:

config: {
  ...
  dependencyTrackingExcludedDomains: [
    'a.example.com',
    'b.example.com',
    '*.c.example.com',
  ],
}

Describe alternatives you've considered
Our feature flag platform also supports SSEs, but falls back to polling if the SSE initialization fails, which happens fairly often.

Additional context
N/A

@elliotleelewis elliotleelewis changed the title [FEATURE REQUEST] Ability to stop requests being tracked for certain domains [FEATURE REQUEST] Ability to stop requests being tracked for array of domains Dec 16, 2020
@MSNev
Copy link
Collaborator

MSNev commented Dec 16, 2020

I've tagged this as an enhancement to effectively pre-configure a set of URL's as excluded from reporting dependencies.
In the short term (until this enhancement can be included) there is already a option that you can use to disable URL's for requests by tagging the XHR instance or passed URL with the AjaxMonitor.DisabledPropertyName or for fetch the request or init parameter.

The code that performs this check is here

// check that this instance is not not used by ajax call performed inside client side monitoring to send data to collector

Once a URL is added (excluding the querystring) it will always be excluded even when follow up requests are not tagged, what this means is that during any initialization / first request to the URL that you want to exclude you can tag the request as such and then everywhere else in your code will automatically exclude the url.

Feel free to review the code and potentially provide a PR to add the capability to auto populate the internal _disabledUrls map with the configured values (I would expect this to be added to the ICorrelationConfig config etc)

@xiao-lix
Copy link
Contributor

Same issue with #1472 Is there a way to disableAjaxTracking for specific ajax requests
Add correct milestone and update release notes. Closing this issue.

@xiao-lix xiao-lix added this to the 2.6.4 milestone Aug 13, 2021
@MSNev MSNev removed the fixed - waiting release PR Committed and waiting deployment label Jan 13, 2022
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 14, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants