ItemSync: Only fetch the items that are actually required.
Review Request #117140 - Created March 28, 2014 and submitted
ItemSync: Only fetch the items that are actually required. ItemSync used to fetch *all* items during *every* sync, which is in most cases completely unnecessary (at least for incremental sync). This patch delays the fetch of items until we know which ones we need, and then only fetches the required ones (usually none), resulting in an IMAP sync going from 10s 100%, to a couple of seconds 1% cpu.
Running it locally, unittest passes.
|This probably should not be there, says Christian||Daniel Vrátil|