CRM-19115 - Synchronize PHP=>MySQL active timezone for all backend scripts #13220
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
In CRM-19115, it was previously observed that
checkMysqlTime
fails when run in some backend/background environments (e.g. REST). This patch is an alternative which tries to fix the problem (mismatch in PHP-MySQL times forextern/rest.php
use-cases) rather than the symptom (undesireable error message).NOTE: For testing, I used the spare CI test node (which has mismatched PHP-MySQL default timezones) and applied #13218 (to re-enable
checkMysqlTime
). In that environment, one could check if the REST end-point has the correct behavior by running:Then simply observe whether
checkMysqlTime
reports an error.Before
System.check
reports thatcheckMysqlTime
fails -- PHP+MySQL are not aligned.After
System.check
reports thatcheckMysqlTime
passes -- PHP+MySQL are aligned.