Closed Bug 1285315 Opened 8 years ago Closed 8 years ago

modify sync code to support non-sync engines

Categories

(Firefox :: Sync, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: glasserc, Assigned: glasserc)

References

Details

Per bug 1253741 and specifically :markh's comment in https://bugzilla.mozilla.org/show_bug.cgi?id=1253741#c9, the storage.sync extension would like to slot in to the sync code somehow so that it can take advantage of the user interface and event loop that already exist. Because the storage.sync extension implementation is based on Kinto, the sync logic itself will not be shared. This bug represents code changes necessary to make Sync be "less opinionated about how abstract 'engines' do what they do".
Assignee: nobody → eglassercamp
Blocks: 1253741
OK, I spent a couple hours poring over the sync code, anticipating a need to separate out the parts of the sync engine code that wouldn't apply to Kinto. I looked at enginesync.js, and there's a lot of stuff there that doesn't seem directly relevant. Even so, it seems like even if we add a Kinto engine, we still need to do almost everything that we do now, because we will always need to sync `clientEngine`. The actual syncing logic itself is dispatched to the engine itself; I think a storage.sync engine would only have to override the `_sync()` method and everything should work OK. In fact, because Kinto sync has some commonalities with Firefox Sync, I might even be able to override the individual `_syncStartup`, `_processIncoming`, `_uploadOutgoing`, `_syncFinish`, and `_syncCleanup` methods. Either way, I think I can close this issue as INVALID.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → INVALID
Component: Firefox Sync: Backend → Sync
Product: Cloud Services → Firefox
You need to log in before you can comment on or make changes to this bug.