Describe the bug
The DataDog SDK when used in web application does periodic (once a second) poll of document.cookie. This is ineffective way to detect changes of cookie. At least on mobile Safari it is very expensive in terms of native code executed by WebKit, see #3548 for more details.
The periodic poll is initiated by:
|
const watchSessionTimeoutId = setInterval(watchSession, STORAGE_POLL_DELAY) |
To Reproduce
Use DD SDK in a Web application.
Expected behavior
There is no polling of document.cookie for the purpose of change detection.
Describe the bug
The DataDog SDK when used in web application does periodic (once a second) poll of
document.cookie. This is ineffective way to detect changes of cookie. At least on mobile Safari it is very expensive in terms of native code executed by WebKit, see #3548 for more details.The periodic poll is initiated by:
browser-sdk/packages/core/src/domain/session/sessionStore.ts
Line 94 in 5a92f20
To Reproduce
Use DD SDK in a Web application.
Expected behavior
There is no polling of
document.cookiefor the purpose of change detection.