File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
pkg/storage/internalstorage Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,7 @@ import (
1414 "github.com/jackc/pgx/v4"
1515 "gopkg.in/natefinch/lumberjack.v2"
1616 "gorm.io/gorm/logger"
17+ "k8s.io/klog/v2"
1718)
1819
1920const (
@@ -216,9 +217,10 @@ func (cfg *Config) genMySQLConfig() (*mysql.Config, error) {
216217 if cfg .MySQL .InterpolateParams != nil {
217218 mysqlconfig .InterpolateParams = * cfg .MySQL .InterpolateParams
218219 }
219- if cfg .MySQL .ParseTime != nil {
220- mysqlconfig . ParseTime = * cfg . MySQL . ParseTime
220+ if cfg .MySQL .ParseTime != nil && ! * cfg . MySQL . ParseTime {
221+ klog . Warningln ( "Mysql query param parseTime=false has been ignored, and set to true" )
221222 }
223+ mysqlconfig .ParseTime = true
222224 if cfg .MySQL .RejectReadOnly != nil {
223225 mysqlconfig .RejectReadOnly = * cfg .MySQL .RejectReadOnly
224226 }
You can’t perform that action at this time.
0 commit comments