-
Notifications
You must be signed in to change notification settings - Fork 582
Exception in NIO client when broker sends a large message over SSL #307
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
@dimas I cannot reproduce locally, but your analysis looks correct. Can you try the latest 4.2.2 SNAPSHOT? Thanks. |
It seem to work.
? |
Adding a few more tests with varying sizes is fine. Refactoring suggestions are best presented as pull requests :) |
Recovery delay was a connection recovery feature from day 1 for a reason: * In practice connection recovery often won't succeed the first time because network failures don't always go away in milliseconds. * There's a natural race condition between server state changes (cleanup of queues and such) and the operations a recovered connection will perform potentially on entities *with the same identifier* (e.g. name) Initial delay avoids a lot of scenarios that stem from the above race condition and can waste a lot of time for operators, developers and the RabbitMQ core team. References #307.
Recovery delay was a connection recovery feature from day 1 for a reason: * In practice connection recovery often won't succeed the first time because network failures don't always go away in milliseconds. * There's a natural race condition between server state changes (cleanup of queues and such) and the operations a recovered connection will perform potentially on entities *with the same identifier* (e.g. name) Initial delay avoids a lot of scenarios that stem from the above race condition and can waste a lot of time for operators, developers and the RabbitMQ core team. References #307. (cherry picked from commit 60eb44d)
Recovery delay was a connection recovery feature from day 1 for a reason: * In practice connection recovery often won't succeed the first time because network failures don't always go away in milliseconds. * There's a natural race condition between server state changes (cleanup of queues and such) and the operations a recovered connection will perform potentially on entities *with the same identifier* (e.g. name) Initial delay avoids a lot of scenarios that stem from the above race condition and can waste a lot of time for operators, developers and the RabbitMQ core team. References #307. (cherry picked from commit 60eb44d)
Recovery delay was a connection recovery feature from day 1 for a reason: * In practice connection recovery often won't succeed the first time because network failures don't always go away in milliseconds. * There's a natural race condition between server state changes (cleanup of queues and such) and the operations a recovered connection will perform potentially on entities *with the same identifier* (e.g. name) Initial delay avoids a lot of scenarios that stem from the above race condition and can waste a lot of time for operators, developers and the RabbitMQ core team. References #307. (cherry picked from commit 60eb44d)
Recovery delay was a connection recovery feature from day 1 for a reason: * In practice connection recovery often won't succeed the first time because network failures don't always go away in milliseconds. * There's a natural race condition between server state changes (cleanup of queues and such) and the operations a recovered connection will perform potentially on entities *with the same identifier* (e.g. name) Initial delay avoids a lot of scenarios that stem from the above race condition and can waste a lot of time for operators, developers and the RabbitMQ core team. References #307. (cherry picked from commit 60eb44d)
Uh oh!
There was an error while loading. Please reload this page.
It looks like there is a bug in how
SslEngineByteBufferInputStream
class "reassembles" the stream.The piece of code below either passes or fails depending on where I set breakpoint.
If breakpoint is at
NioHelper.read
(so there is some time for data from the network be available and bytesRead be above zero) - it works.However if breakpoint is set to the next line, data from the network is not yet available and
else
branch is executed. It eventually reads the data but never doescipherIn.flip();
so unlike the the "then" branch which exits with cipherIn(position=0, limit=4629) in my test, the "else" branch exits cipherIn(position=4629, limit=16921) - I guess it is still in "read" mode. That later fails onsslEngine.unwrap()
. If I manually invokecipherIn.flip()
in the debugger, the packet seem to decode ok.The text was updated successfully, but these errors were encountered: