File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -67,6 +67,7 @@ def mysql_connection(config)
67
67
# with reconnect fail-over sets connection read-only (by default)
68
68
# properties['failOverReadOnly'] ||= 'false'
69
69
end
70
+ properties [ 'noDatetimeStringSync' ] = true unless properties . key? ( 'noDatetimeStringSync' )
70
71
end
71
72
if config [ :sslkey ] || sslcert = config [ :sslcert ] # || config[:use_ssl]
72
73
properties [ 'useSSL' ] ||= true # supported by MariaDB as well
@@ -89,11 +90,12 @@ def mysql_connection(config)
89
90
properties [ 'localSocket' ] ||= socket if mariadb_driver
90
91
end
91
92
93
+ # properties['useJDBCCompliantTimezoneShift'] ||= true
92
94
# for the Connector/J 5.1 line this is true by default - but it requires some really nasty
93
95
# quirks to get casted Time values extracted properly according for AR's default_timezone
94
96
# - thus we're turning it off (should be off in newer driver versions >= 6 anyway)
95
97
# + also MariaDB driver is compilant and we would need to branch out based on driver
96
- properties [ 'useLegacyDatetimeCode' ] = false
98
+ properties [ 'useLegacyDatetimeCode' ] = false # disables the effect of 'useTimezone'
97
99
98
100
jdbc_connection ( config )
99
101
end
You can’t perform that action at this time.
0 commit comments