Type: User story
Affects Version/s: None
Fix Version/s: 8.3
Component/s: Nuxeo Drive
Mostly by refactoring DocumentBackedFolderItem#getChildren to use a ecm:path STARTSWITH or ecm:ancestorId = clause instead of making the client recursively call getChildren.
We need to handle pagination here.
The ecm:path / ecm:ancestorId clause should be OK if path optimiations are applied which is the case by default, even in 6.0.
Yet, in VCS, ORDER BY ecm:path cannot be done by the database so it's done in Java by fetching all the documents in memory then sorting them and performing a manual LIMIT/OFFSET (if specified).
=> In this case paginating won't be effficient!
So if we want to do pagination we need to sort by ecm:uuid or anything determinisitic.