Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Avoid false warning about UTC timestamps #505

Merged

Conversation

GeorgEchterling
Copy link
Contributor

@GeorgEchterling GeorgEchterling commented Jun 21, 2024

If the JDBC customization is already correctly configured, SchedulerClient.Builder.build should not instantiate an unused incorrectly configured one.

Fixes

Instantiating a SchedulerClient on MariaDB always logged the UTC warning, even when using a correctly configured JDBC customization:

SchedulerClient.Builder.create(dataSource)
            .jdbcCustomization(AutodetectJdbcCustomization(dataSource, true))
            .build()
2024-06-21T15:44:33.427+02:00  WARN 57277 --- [  restartedMain] c.g.k.s.j.A.utc_warning                  : MariaDB-schema does not support persistent timezones. It is recommended to store time in UTC to avoid issues with for example DST. For first time users, use setting 'alwaysPersistTimestampInUtc' to achieve this. Users upgrading from a version prior to v14.0.0 can either silence this logger, or perform a controlled upgrade to UTC timestamps. All old instances of the scheduler must be stopped and timestamps migrated to UTC before starting again, using 'alwaysPersistTimestampInUtc=true'.

(I did not create a separate issue for this.)


cc @kagkarlsson

If the JDBC customization is already correctly configured,
SchedulerClient.Builder.build should not instantiate
an unused incorrectly configured one.
@kagkarlsson
Copy link
Owner

Ah, nice catch 👍. Thank you for fixing

@kagkarlsson kagkarlsson merged commit 60a3f76 into kagkarlsson:master Jun 21, 2024
6 checks passed
@kagkarlsson kagkarlsson added the released Issue has been released label Jul 1, 2024
@kagkarlsson
Copy link
Owner

🎉 This issue has been resolved in v14.0.2 (Release Notes)

@GeorgEchterling GeorgEchterling deleted the bugfix/avoid-false-utc-warning branch July 17, 2024 10:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
released Issue has been released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants