zhangshuyan0 opened a new pull request, #5900:
URL: https://github.com/apache/hadoop/pull/5900

   ### Description of PR
   
   The result of `getListing` in NameNode are sorted based on `byte[]`, while 
the Router side is based on `String`. If there are special characters in path, 
the sorting result of the router will be inconsistent with the namenode. This 
may result in duplicate `getListing` results obtained by the client due to 
wrong `startAfter` parameter.
   For exemple, namenode returns [path1, path2, path3] for a `getListing` 
request, while router returns [path1, path3, path2] to client. Then client will 
pass `path2` as `startAfter`  at the next iteration, so it will receive `path3` 
again.
   We need to fix the Router code so that the order of its result is the same 
as NameNode.
   
   ### How was this patch tested?
   Add a new unit test.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to