Skip to content

Throw MySqlProtocolException for short packet #394

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

Closed
bgrainger opened this issue Nov 7, 2017 · 1 comment
Closed

Throw MySqlProtocolException for short packet #394

bgrainger opened this issue Nov 7, 2017 · 1 comment
Assignees
Milestone

Comments

@bgrainger
Copy link
Member

If a received packet has insufficient data, throw MySqlProtocolException instead of EndOfStreamException.

This is a more descriptive exception type (and the underlying connection may not be a Stream).

@bgrainger bgrainger added this to the 1.0 milestone Nov 7, 2017
@bgrainger bgrainger self-assigned this Nov 7, 2017
@bgrainger
Copy link
Member Author

A problem with switching to MySqlProtocolException is that it conflates "packet received out of order" (probably a bug, needs to be surfaced and reported here as an issue, e.g., #267) and "server closed connection" (often recoverable, e.g., #208).

Leaving as EndOfStreamException for now.

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

No branches or pull requests

1 participant