The Wayback Machine - https://web.archive.org/web/20201125064007/https://github.com/go-sql-driver/mysql/issues/1106
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

Implement database/sql/driver.Validator interface #1106

Open
julienschmidt opened this issue May 21, 2020 · 5 comments
Open

Implement database/sql/driver.Validator interface #1106

julienschmidt opened this issue May 21, 2020 · 5 comments

Comments

@julienschmidt
Copy link
Member

@julienschmidt julienschmidt commented May 21, 2020

Issue description

Go 1.15 will introduce a new Validator interface, which may be implemented by Conn to allow drivers to signal if a connection is valid or if it should be discarded:

https://tip.golang.org/pkg/database/sql/driver/#Validator

@dilantha111
Copy link

@dilantha111 dilantha111 commented May 24, 2020

If anyone haven't started on this, I would like to have a look

@julienschmidt
Copy link
Member Author

@julienschmidt julienschmidt commented May 24, 2020

Go ahead. I assigned you :)

@shogo82148
Copy link
Contributor

@shogo82148 shogo82148 commented Sep 1, 2020

@dilantha111 Hi, have you started on this?
Go 1.15 is already released, so I'm looking forward this.

@dilantha111 dilantha111 removed their assignment Oct 19, 2020
@dilantha111
Copy link

@dilantha111 dilantha111 commented Oct 19, 2020

Hi @shogo82148 sorry that I was very too late to respond. But now my focus has been shifted, and no longer in go development. I think it's better someone else look into this. Thanks.

@trongbq
Copy link

@trongbq trongbq commented Nov 24, 2020

@julienschmidt If you don't mind, I would like to send a PR for this issue.
My idea is to use mysqlConn#error() method to check if there is any errors atm, then return bool value respectively.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.