DescriptionMake the BackgroundFetchJobController a per-job object
In previous code, the BackgroundFetchJobController had information about
all jobs in progress. In this CL, multiple job controllers are instantiated,
and each controller monitors a single job. This allows the controller to
be later used as an Observer for the particular files in its job.
Also changed in this CL is the ownership model for the JobData. Instead of
the DataManager keeping ownership of the JobData, the ownership is passed
to the JobController. The Context then keeps ownership of all created
JobControllers and calls Shutdown on the controllers before the DataManager
is destroyed.
There is still temporary storage for the JobInfo and RequestInfos which will
eventually be written to permanent storage, but these temporary data
structures have been more explicitly called out as temporary.
BUG=692544
Review-Url: https://codereview.chromium.org/2724783002
Cr-Commit-Position: refs/heads/master@{#455869}
Committed: https://chromium.googlesource.com/chromium/src/+/35b3ce0d6309b6cc8ad83084aa0e0365ae1e2b5a
Patch Set 1 #
Total comments: 30
Patch Set 2 : Fixed destructor threading and nits #
Total comments: 6
Patch Set 3 : nits and formatting. #Patch Set 4 : Fix protection for DeleteOnIOThread template issue. #Patch Set 5 : ACTUALLY fix the compile error #Depends on Patchset: Dependent Patchsets: Messages
Total messages: 27 (16 generated)
|