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

Switch from mysql to mysql2 #434

Open
8secz-johndpope opened this issue Aug 25, 2020 · 4 comments
Open

Switch from mysql to mysql2 #434

8secz-johndpope opened this issue Aug 25, 2020 · 4 comments

Comments

@8secz-johndpope
Copy link

https://www.npmjs.com/package/mysql2

seems like mysql2 has a bump in performance.

MySQL client for Node.js with focus on performance. Supports prepared statements, non-utf8 encodings, binary log protocol, compression, ssl

@8secz-johndpope
Copy link
Author

Screen Shot 2020-08-25 at 1 03 29 pm

I ran test suite and seems to pass.

@bajtos
Copy link
Member

bajtos commented Aug 28, 2020

Hi @8secz-johndpope, there is no particular reason. The connector was created before mysql2 even existed, we haven't had bandwidth to look for alternative drivers and evaluate if it's worth switching.

From what I remember, dealing with types like Date, Time and DateTime can be tricky, especially regarding the timezones. Does mysql2 handle time-related types the same way as mysql?

Our main issue with mysql is lack of support for new authentication protocols introduced by MySQL version 8 (see mysqljs/mysql#2002). It would be a great reason for switching if mysql2 supported them. I am not sure if that's the case though - see sidorares/node-mysql2#991, sidorares/node-mysql2#906 and related issues.

@bajtos bajtos added community-contribution Patches contributed by community and removed community-contribution Patches contributed by community labels Aug 28, 2020
@stale
Copy link

stale bot commented Dec 25, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 25, 2020
@bajtos bajtos changed the title Is there a reason this repo is not using mysql2? Switch from mysql to mysql2 Jan 6, 2021
@samarpanB
Copy link
Collaborator

Fixed with #484

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

No branches or pull requests

3 participants