MDL-72359 core_analytics: Better handling of MAX_TIME

We are limited by both PHP's max int value and DB (cross-db) max int allowed.
We need to use the smallest one
This commit is contained in:
Huong Nguyen 2023-08-29 20:07:38 +07:00
parent 8b40e8a7b9
commit be57a10c08
No known key found for this signature in database
GPG key ID: 40D88AB693A3E72A

View file

@ -37,8 +37,9 @@ interface analysable {
/** /**
* Max timestamp. * Max timestamp.
* We are limited by both PHP's max int value and DB (cross-db) max int allowed. Use the smallest one.
*/ */
const MAX_TIME = PHP_INT_MAX; const MAX_TIME = PHP_INT_MAX < 9999999999 ? PHP_MAX_INT : 9999999999;
/** /**
* The analysable unique identifier in the site. * The analysable unique identifier in the site.