Hi all,
I create a PR(https://github.com/apache/ratis/pull/654) which corresponds to 
Issue(https://issues.apache.org/jira/browse/RATIS-1587 
<https://issues.apache.org/jira/browse/RATIS-1587>).

In this PR:
Fix snapshot multiple-chunk bug. Currently, when leader install a 
snapshot(multiple chunks) to a newly joined follower, leader will send multiple 
InstallSnapshot RPCs. However, each RPC will create a tmp dir with Random UUID, 
place the chunk in this tmp dir, and only renames the last tmp dir to sm-dir. 
In this PR, I propose to create tmp dir using request.uuid(), which remains 
unchanged among multiple RPCs.

Fix Grpc Stream errors. Currently In grpc.proto, InstallSnapshot is declaimed 
as client-end streaming rpc, but it is actual bi-directional streaming rpc. In 
this PR, I addded stream to InstallSnapshot proto so that it becomes 
bi-directional.

Support snapshot file hierarchy. Currently all files of a snapshot will be 
placed in statemachine dir and file hierarchy is flattened. In this PR, I name 
each file using its original filename (which contains hierarchy information).

Please help me review this PR and welcome to give any advices :)

Best wishes,
William Song

Reply via email to