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: Only ignore PutRumEvents requests on proxy endpoints. #266

Merged
merged 1 commit into from
Oct 25, 2022

Conversation

qhanam
Copy link
Member

@qhanam qhanam commented Oct 18, 2022

The web client currently ignores resource timings where the resource has the same host name as the RUM data plane endpoint. While this prevents an infinite loop of recording PutRumEvents requests, it is problematic when PutRumEvents requests are proxied through the same endpoint as the application server.

For example, I may have an endpoint which routes the following paths:

  1. https://myapp.amazonaws.com/user
  2. https://myapp.amazonaws.com/gamma/application/aa17a42c-e737-48f7-adaf-2e0905f48073/events

In case (1), the request is related to the application logic, and the web client should record the request.

In case (2), the request is related to RUM, and the web client should not record the request.

This change solves the problem by checking the path fragment of the resource URL in addition to the host name of the resource URL. This allows the web client to disambiguate application requests from PutRumEvents proxy requests.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@qhanam qhanam merged commit 74e6436 into aws-observability:main Oct 25, 2022
@qhanam qhanam deleted the fix-excluded-endpoint-url branch October 25, 2022 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.

None yet

3 participants