[ 
https://issues.apache.org/jira/browse/RATIS-499?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16795267#comment-16795267
 ] 

Lokesh Jain commented on RATIS-499:
-----------------------------------

[~szetszwo] Thanks for working on this! The patch looks good to me. Please find 
my comments below.
 # GrpcClientProtocolClient#orderedStreamObservers - This should be updated 
when the existing orderedStreamObserver is closed.
 # In GrpcClientProtocolService, we are handling the case where leader 
shutsdown. I think we also need to handle the case for a non-leader receiving 
these requests. For a non-leader this stream observer will be active because 
client can send requests to any server. Further there can be read requests to 
server. Therefore the non-leader can have certain requests in its sliding 
window which can be applied out of order if this non-leader becomes leader. 
Therefore I was thinking if we should reset server sliding window every time 
the reply is sent with NotLeaderException set?

> Server should close the sliding window if it steps down
> -------------------------------------------------------
>
>                 Key: RATIS-499
>                 URL: https://issues.apache.org/jira/browse/RATIS-499
>             Project: Ratis
>          Issue Type: Bug
>          Components: gRPC, server
>            Reporter: Tsz Wo Nicholas Sze
>            Assignee: Tsz Wo Nicholas Sze
>            Priority: Major
>         Attachments: r499_20190314.patch, r499_20190318.patch, 
> r499_20190318b.patch
>
>
> The situation described in RATIS-459 is still possible if a server is not 
> restarted.  A simple solution is to close the sliding window if there is a 
> NotLeaderException.  indeed, we should close all client connections when a 
> leader steps down.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to