service: add prototype of a streaming filesChangedSince API
service: add prototype of a streaming filesChangedSince API

Summary:
The Watchman<->EdenFS interaction has a couple of issues currently especially
regarding the handling of since queries. In particular, resolving since queries
correctly across checkout operations involves collecting all the files changed
in between the commits. This also includes all the files that aren't even in
the working copy for correctness reasons.

One of the major issue with this is that this is effectively a O(repo)
operation which tools like Watchman and EdenFS were designed to avoid in the
first place. One easy way to see this is to think about what data
EdenFS/Watchman will need to load when a checkout between the null commit and
the last commit in the repository involves: all the trees in the repository
will need to be loaded and thus fetched.

In a previous diff, this got partially hacked around by short-circuiting some
of the work above by adding a threshold on the number of files Watchman will
start returning fresh instances to clients. Unfortunately, this doesn't removes
the need for Watchman to compute the changes in the first place and thus the
tree fetches.

To solve this a new streaming API is introduced which will compute the set of
files changed (including the ones from updates) between 2 journal positions.
The client will be expected to first get the current journal position and call
this API with it and its last known journal position.

Reviewed By: chadaustin

Differential Revision: D35629448

fbshipit-source-id: 844174c0b41228c81993a3e11265a5e87e7e4690

facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman,facebook/watchman