Skip to content

Commit

Permalink
Update heavy customer data warning (#2316)
Browse files Browse the repository at this point in the history
  • Loading branch information
amortemousque authored Jul 7, 2023
1 parent 53c211a commit 5b05ad0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ describe('warnIfCustomerDataLimitReached', () => {
const warned = warnIfCustomerDataLimitReached(CUSTOMER_DATA_BYTES_LIMIT + 1, CustomerDataType.User)
expect(warned).toEqual(true)
expect(displaySpy).toHaveBeenCalledWith(
"The user data is over 3KiB. On low connectivity, the SDK has the potential to exhaust the user's upload bandwidth."
'The user data exceeds the recommended 3KiB threshold. More details: https://docs.datadoghq.com/real_user_monitoring/browser/troubleshooting/#customer-data-exceeds-the-recommended-3kib-warning'
)
})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ export const enum CustomerDataType {
export function warnIfCustomerDataLimitReached(bytesCount: number, customerDataType: CustomerDataType): boolean {
if (bytesCount > CUSTOMER_DATA_BYTES_LIMIT) {
display.warn(
`The ${customerDataType} data is over ${
`The ${customerDataType} data exceeds the recommended ${
CUSTOMER_DATA_BYTES_LIMIT / ONE_KIBI_BYTE
}KiB. On low connectivity, the SDK has the potential to exhaust the user's upload bandwidth.`
}KiB threshold. More details: https://docs.datadoghq.com/real_user_monitoring/browser/troubleshooting/#customer-data-exceeds-the-recommended-3kib-warning`
)
return true
}
Expand Down

0 comments on commit 5b05ad0

Please sign in to comment.