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

Add rarely used http features #398

Closed
wants to merge 4 commits into from
Closed

Conversation

peel
Copy link
Contributor

@peel peel commented Nov 17, 2023

Warning

🚧 Part of 3.1.0. Will rebase on top of stable develop when 3.0.0 is released.

Adds the ability to configure collector's root (GET /) response. If rootResponse.enabled = true when / is requested a static, configured response is returned.

With status code equal to rootResponse.statusCode, http headers of rootResponse.headers and
body of rootResponse.body.

@peel peel force-pushed the feature/root-response branch from 41c6231 to 8bc9df3 Compare November 23, 2023 18:30
@peel peel changed the title Add http root response (close #397) Add rarely used http features Dec 4, 2023
@peel peel force-pushed the feature/root-response branch 2 times, most recently from 44c3df7 to 3106307 Compare December 5, 2023 09:09
peel added 3 commits December 5, 2023 16:24
Adds the ability to configure collector's root (GET `/`) response.
If `rootResponse.enabled = true` when `/` is requested a static, configured
response is returned.

With status code equal to `rootResponse.statusCode`,
http headers of `rootResponse.headers` and
body of `rootResponse.body`
crossdomain.xml provides cross-domain functionality to Adobe Flash/Flex, but these days Adobe Acrobat. The functionality is required when a tracker request is embedded in a pdf. In this case, when user opens up a PDF file with a script hosted on domain a.com, the script will fetch the crossdomain.xml policy from domain b.com to check whether the endpoint can be accessed and that's used by Adobe to conditionally issue requests.
This is a server-side option to disable tracking once events are received from a
tracker. These requests are not sank and instead are silently discarded.
Trackers also enable a similar mechanism[1] that will not pass events to the
collector.
This is likely a better approach, but having it in the collector is another
prevention mechanism.

1 - https://docs.snowplow.io/docs/collecting-data/collecting-from-own-applications/javascript-trackers/web-tracker/tracker-setup/initialization-options/#respecting-do-not-track
@spenes spenes force-pushed the feature/root-response branch from 3106307 to b6315e6 Compare December 5, 2023 13:28
Copy link
Contributor

@spenes spenes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@peel
Copy link
Contributor Author

peel commented Dec 18, 2023

Rebased into 3.0.0

@peel peel closed this Dec 18, 2023
@peel peel deleted the feature/root-response branch November 21, 2024 13:49
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