Explain default setting for TLS param in DSN

This commit is contained in:
Brandon Bodnar 2019-01-31 17:23:19 -06:00
parent dc599bb036
commit c440112d44

View File

@ -91,6 +91,8 @@ func (this *ConnectionConfig) GetDBUri(databaseName string) string {
hostname = fmt.Sprintf("[%s]", hostname) hostname = fmt.Sprintf("[%s]", hostname)
} }
interpolateParams := true interpolateParams := true
// go-mysql-driver defaults to false if tls param is not provided; explicitly setting here to
// simplify construction of the DSN below.
tlsOption := "false" tlsOption := "false"
if this.tlsConfig != nil { if this.tlsConfig != nil {
tlsOption = this.Key.StringCode() tlsOption = this.Key.StringCode()