-
Notifications
You must be signed in to change notification settings - Fork 341
MySqlDataReader.CreateAsync throws misleading exception #667
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
This call stack looks like a bug in MySqlConnector:
It's coming from https://github.com/mysql-net/MySqlConnector/blob/0.56.0/src/MySqlConnector/MySql.Data.MySqlClient/MySqlDataReader.cs#L306 The code is trying to clean up the Probably the exception you should be getting is the "Command Timeout expired" one. You may need to set |
Instead of increasing the timeout, we actually need to optimize some queries, still, in the meantime we can use that as a workaround :) |
This logic flow has already been rewritten (on |
Do you have any test case for a timeout ? |
I have test cases for various command timeouts, but wasn't able to repro this specific problem with them yet. |
I never noticed this in your original post. And I assume (from the call stack) that you have I was able to reproduce this with 0.56.0, but not 0.57.0-beta9. I believe this was already fixed in 8220c3e (which was authored before you opened this issue), but hasn't shipped in a stable release yet. Updating to the latest beta should fix this issue, but note that #672 is still potentially affecting the execution of stored procedures. |
Yes, in some stored procedures we have out parameters to get the for example the page count or the id of the inserted record. |
0.57.0-rc1 is available to test the fix. |
We're experiencing an issue with MySQLConnector when facing a timeout.
We call a stored procedure using Dapper, the timeout happens and we get the following log from MySqlConnectorLogger
But, the exception that we get on the catch of the business object is the following:
This is causing some confusion, as we have similar messages in other places, it makes us wonder if the bug is because the next execution tries to make a call to MySQL Server and the connection is on an unexpected state.
We're using AWS Aurora, and the only thing "extra" on the connection string is CharSet=utf8mb4;
Can you clarify the meaning of "Connection must be Open; current state is Closed" ?
The text was updated successfully, but these errors were encountered: