-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Throw an error when a connection ends with a RST,ACK packet? #1811
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
Comments
Can you provide the fix or help me setup an Azure MySQL instance to run the code against? |
Sure, please give me an email address and I'll send you the connections parameters. |
Use the one on my GitHub profile :) |
@alex030293 provided a connection to a MySQL Azure instance and I reproduced the issue and have a tentative fix. I should land the fix on |
Sorry for the delay, I'm still trying to figure out how to actually make a test for this. It seems like Node.js does not treat a RST as an error unless it thinks it has something to read. It only seems to be an issue with the ACK from the sent data is combined with the RST, but if the ACK and RST are separate Node.js doesn't throw an error. I can't seem to get Node.js code to get them to emit together so far, through, in order to create a test. |
@elemount I think in an issue somewhere you said Azure team would be willing to provide a server I can connect the CI of this project to. That would be awesome and definitely help out with this issue, which I cannot figure out how to get a working test for without having an Azure MySQL server in the test suite. Travis CI has the ability to use encrypted secrets in the config, so I can add the credentials to the CI without them being available to the public. |
Let me email to him and let he connect with you. |
I have been chasing unhandled I am getting
The What should the |
Ok, I got the instructions for how to get the Azure MySQL setup, so I'll work on getting it running in our CI for this issue. |
@dougwilson Any update on this? Should we expect this to be fixed in next release? Is there any ETA for next release? Thanks |
I have a failing branch pushed up right now. Still need to get Azure set up and finish the changes. This is what is holding the next release, so yes it is expected in the next release. |
Here is the branch if you want to take a look / try: https://github.com/mysqljs/mysql/tree/quit-rst |
I merged the change into |
According to MySQL docs,
COM_QUIT
command should end with "either a connection close or a OK_Packet".As @elemount pointed out in issue #1730, Azure MySQL is answering with an
RST,ACK
.It can be reproduced when you run this example code against an Azure MySQL instance.
Throws ECONNRESET error.
Should this library throw an error when a connection end with a
RST
with theACK
flag set?Can we detect this?
The text was updated successfully, but these errors were encountered: