Skip to content

Update discoverRootDomain default behaviour - #1350

Merged
Jethro Nederhof (jethron) merged 1 commit into
snowplow:release/4.0.0from
jethron:discover-root-default
Oct 8, 2024
Merged

Update discoverRootDomain default behaviour#1350
Jethro Nederhof (jethron) merged 1 commit into
snowplow:release/4.0.0from
jethron:discover-root-default

Conversation

@jethron

Copy link
Copy Markdown
Contributor

In v3, discoverRootDomain was disabled by default, and enabling it meant ignoring the cookieDomain configuration. If neither were set, cookies would have no Domain attribute attached and would bind to the current domain; cookies with no domain are unique in that they do not get shared to subdomains.

In 257ddb3 we updated the discoverRootDomain setting to default to enabled, and changed how it interacted with the cookieDomain setting so that discoverRootDomain is essentially always enabled, but gets ignored if cookieDomain is also specified. This however made it impossible to use the 'no domain' behaviour available in v3, because disabling discoverRootDomain would have no effect without specifying cookieDomain as well.

This can be slightly confusing, so instead, this change allows explicitly disabling discoverRootDomain even if no cookieDomain is specified, allowing the same behaviour as all configurations available in v3.

In v3, `discoverRootDomain` was disabled by default, and enabling it
meant ignoring the `cookieDomain` configuration. If neither were set,
cookies would have no `Domain` attribute attached and would bind to the
current domain; cookies with no domain are unique in that they do not
get shared to subdomains.

In 257ddb3 we updated
the `discoverRootDomain` setting to default to enabled, and changed how it
interacted with the `cookieDomain` setting so that `discoverRootDomain`
is essentially always enabled, but gets ignored if `cookieDomain` is
also specified. This however made it impossible to use the 'no domain'
behaviour available in v3, because disabling `discoverRootDomain` would
have no effect without specifying `cookieDomain` as well.

This can be slightly confusing, so instead, this change allows
explicitly disabling `discoverRootDomain` even if no `cookieDomain` is
specified, allowing the same behaviour as all configurations available
in v3.
@bundlemon

bundlemon Bot commented Oct 4, 2024

Copy link
Copy Markdown

BundleMon

Files added (6)
Status Path Size Limits
trackers/javascript-tracker/dist/sp.js
+24.26KB 30KB / +10%
libraries/browser-tracker-core/dist/index.mod
ule.js
+23.42KB 25KB / +10%
libraries/tracker-core/dist/index.module.js
+19.12KB 20KB / +10%
trackers/browser-tracker/dist/index.umd.min.j
s
+17.24KB 20KB / +10%
trackers/javascript-tracker/dist/sp.lite.js
+17.19KB 20KB / +10%
trackers/browser-tracker/dist/index.module.js
+3.49KB 5KB / +10%

Total files change +104.71KB 0%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

@jethron
Jethro Nederhof (jethron) merged commit af9992a into snowplow:release/4.0.0 Oct 8, 2024
@jethron
Jethro Nederhof (jethron) deleted the discover-root-default branch October 8, 2024 23:19
Matus Tomlein (matus-tomlein) pushed a commit that referenced this pull request Oct 25, 2024
In v3, `discoverRootDomain` was disabled by default, and enabling it
meant ignoring the `cookieDomain` configuration. If neither were set,
cookies would have no `Domain` attribute attached and would bind to the
current domain; cookies with no domain are unique in that they do not
get shared to subdomains.

In 257ddb3 we updated
the `discoverRootDomain` setting to default to enabled, and changed how it
interacted with the `cookieDomain` setting so that `discoverRootDomain`
is essentially always enabled, but gets ignored if `cookieDomain` is
also specified. This however made it impossible to use the 'no domain'
behaviour available in v3, because disabling `discoverRootDomain` would
have no effect without specifying `cookieDomain` as well.

This can be slightly confusing, so instead, this change allows
explicitly disabling `discoverRootDomain` even if no `cookieDomain` is
specified, allowing the same behaviour as all configurations available
in v3.
Matus Tomlein (matus-tomlein) pushed a commit that referenced this pull request Oct 28, 2024
In v3, `discoverRootDomain` was disabled by default, and enabling it
meant ignoring the `cookieDomain` configuration. If neither were set,
cookies would have no `Domain` attribute attached and would bind to the
current domain; cookies with no domain are unique in that they do not
get shared to subdomains.

In 257ddb3 we updated
the `discoverRootDomain` setting to default to enabled, and changed how it
interacted with the `cookieDomain` setting so that `discoverRootDomain`
is essentially always enabled, but gets ignored if `cookieDomain` is
also specified. This however made it impossible to use the 'no domain'
behaviour available in v3, because disabling `discoverRootDomain` would
have no effect without specifying `cookieDomain` as well.

This can be slightly confusing, so instead, this change allows
explicitly disabling `discoverRootDomain` even if no `cookieDomain` is
specified, allowing the same behaviour as all configurations available
in v3.
Matus Tomlein (matus-tomlein) pushed a commit that referenced this pull request Oct 28, 2024
In v3, `discoverRootDomain` was disabled by default, and enabling it
meant ignoring the `cookieDomain` configuration. If neither were set,
cookies would have no `Domain` attribute attached and would bind to the
current domain; cookies with no domain are unique in that they do not
get shared to subdomains.

In 257ddb3 we updated
the `discoverRootDomain` setting to default to enabled, and changed how it
interacted with the `cookieDomain` setting so that `discoverRootDomain`
is essentially always enabled, but gets ignored if `cookieDomain` is
also specified. This however made it impossible to use the 'no domain'
behaviour available in v3, because disabling `discoverRootDomain` would
have no effect without specifying `cookieDomain` as well.

This can be slightly confusing, so instead, this change allows
explicitly disabling `discoverRootDomain` even if no `cookieDomain` is
specified, allowing the same behaviour as all configurations available
in v3.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants