-
Notifications
You must be signed in to change notification settings - Fork 0
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
Merge changes from original repo #9
Conversation
…s auth response handling code into func to reduce some duplication of logic. Test requires a MySQL socket and user having privs to use it.
Also add unit test.
Fix tests with MySQL 5.7.9
QueryUnescape the tlsConfig name during DSN parsing.
…broken-pipe-error Fixes #389 by not sending COM_QUIT until authenticated. Also refactor…
Pull recent changes from the main fork
Use Errorf instead of Error in the correct places
Travis: Test with Go 1.5
Export ParseDSN and Config
- use local attributes for timeouts - do not type assert to net.Conn each time - DSN params are CamelCase
Add readTimeout and writeTimeout params
read / write timeouts
users may rely on it
- packets.go: flag clientMultiResults, update status when receiving an EOF packet, discard additional results on readRow when EOF is reached - statement.go: currently a nil rows.mc is used as an eof, don’t set it if there are no columns to avoid that Next() waits indefinitely - rows.go: discard additional results on close and avoid panic on Columns()
``` $ go vet driver_test.go:308: arg out for printf verb %t of wrong type: int exit status 1 ```
Fix error reported by `go vet`
This sets attribute _client_name with the value "Go MySQL Driver" Also sets _os, _platform, _pid and program_name by default. This also decodes the uppper two bytes of the capability flags. The dsn_test.go only tests for one attribute because there is no guaranteed sort order for a map and Printf %+v as used by TestDSNParser().
Support for connection attributes
test and fix for MysSQL float parsing into float64 when placeholders are used Fixes #433
Fix dsn_test.go to work with Go 1.7
readUntilEOF should support ERR packet
Allows to set the driver-side max_packet_allowed value manually * add docs * add author, add test * fix AUTHOR file and README * change the param name from MaxPacketAllowed to MaxAllowedPacket * fix maxAllowedPacket param name in README * rename all maxPacketAllowed to maxAllowedPacket * fix doc format * fix doc
The strict mode may not be confused with the server-side strict mode set via the sql_mode system variable. Fixes #376 * README: Set strict mode via sql_mode in DSN example
Also make linebreaks consistent
@gkristic is this the right way of updating our mysql driver? I'd like to get a bunch of changes, like the ability of setting timeouts on connections so a network problem does not cause ~infinite stalls. This would be required to solve https://github.com/VividCortex/node-health/issues/13 without doing some ugly workarounds around the driver. |
closed by mistake :) |
particularly interested in go-sql-driver#372 and go-sql-driver#401 |
This is actually important for all of our services. |
…on (#494) * Support authentication switch with mysql_native_password authentication. Besides, fix bug that cipher needs to refreshed from authentication switch request packet from server. * revert connection.go which was modified by accident. * Address comments. * Keep DSN params sorted * DSN: Add code to format allowNativePasswords
I see that there are a few updates in our own copy, like #5, that I'm not sure were finally contributed to the original repo. Hence, we need to make sure that everything is still consistent when pulling these changes. Also, I don't think we're running automated tests for this repo. Make sure tests pass before merging. |
I did it as a separate branch: #10 |
Merge changes from original repo