digitalpetri / netty-channel-fsm

An FSM that manages async non-blocking access to a Netty Channel
Eclipse Public License 2.0
16 stars 8 forks source link

Add SessionFsm::getChannel overload with `waitForReconnect` parameter #2

Closed kevinherron closed 3 years ago

kevinherron commented 3 years ago

Introduce a new overload that offers control over the behavior of SessionFsm::getChannel when the FSM is in the ReconnectWait state. When true, it behaves the same as the parameterless call and the CompletableFuture won't be completed until a connection attempt has been made. When false, the returned CompletableFuture will have already been completed exceptionally.