[Sync::USS] Refactor BookmarkModelTypeProcessor
This CL extracts the logics for handling remote updates and committing local updates into BookmarkRemoteUpdatesHandler and BookmarkLocalChangesBuilder respectively. This is to simplfy the BookmarkModelTypeProcessor. Before this CL: processor scheduled metadata save only if there is a change in the metadata without change in the model, because the model would trigger the save in such cases. After this CL: processor schedules metadata save every time remote updates are processed regardless from they entailed a change in the model or not. This simplifies the code, and the bookmark storage should squash subsequent save requests, so consecutive save requests from the model and the processor should result in only one actually save on disk. Bug: 516866 Change-Id: I7918086b31b11f7a72804b152f23af2b059cca3d Reviewed-on: https://chromium-review.googlesource.com/1124854 Commit-Queue: Mohamed Amir Yosef <mamir@chromium.org> Reviewed-by:Mikel Astiz <mastiz@chromium.org> Cr-Commit-Position: refs/heads/master@{#572514}
Showing
This diff is collapsed.
This diff is collapsed.
Please register or sign in to comment