Closed Bug 1157553 Opened 10 years ago Closed 10 years ago

Sync history

Categories

(Firefox for iOS :: Sync, defect)

All
iOS 8
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: rnewman, Assigned: rnewman)

References

Details

Attachments

(1 file)

47 bytes, text/x-github-pull-request
nalexander
: review+
Details | Review
No description provided.
Hi Richard, unfortunately this report is not very useful because it does not describe the problem well. If you have time and can still reproduce the problem, please read https://developer.mozilla.org/en-US/docs/Mozilla/QA/Bug_writing_guidelines and add a more useful description to this report.
Flags: needinfo?(rnewman)
Andre - While true, comment 0 is not full of helpful descriptive text, I think this bug is a placeholder for Richard. It's likely that no one else but Richard will be taking this bug.
Flags: needinfo?(rnewman)
Pre: 3456084
Depends on: 1159561
Depends on: 1159562
Depends on: 1159563
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
(Sorry, that's "pre" stuff.)
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Depends on: 1160399
Depends on: 1163273
Time to capture some notes about visits. The Sync history record format[1] is "open-world": 1. the set of items is not comprehensive -- you might have visited URLs that are not on the server. That's true for two reasons: clients upload no more than 5,000 history items (my profile has over 100,000), and no more than 30 days' worth; and the server discards history items after 60 days[2]. 2. the set of visits for each item is not comprehensive -- you might have visited a URL more times than the history record indicates. That's because desktop includes no more than 10 visits in a payload[3]. Changing these two assumptions would be impossible: 1. 100,000 history records is prohibitive to store or download for each user. 2. the max size of a Sync record isn't enough to store 4,000+ visits (apparently I visit Twitter and Facebook a lot). As such, my neat formalism -- throw away remote visits and replace them every time we download a changed record -- can't be used. Furthermore, we're not able to delete individual visits without extending the record format to include a notion of a deleted visit. That's possible, but not something to address right now. As a result, we always need to do additive merging, and we need to carefully consider how deletion works -- it's not possible for us to tell other clients to throw away all visits but _these_, only to throw away all visits for a URL, and only if they've already synced and have the right GUID! *shakes fist at Sync* [1] <http://docs.services.mozilla.com/sync/objectformats.html#id4> [2] <http://mxr.mozilla.org/mozilla-central/source/services/sync/modules/engines/history.js#12> [3] Bug 1164660.
Attached file Pull req.
Time to get started on this. One thing still needs to be done, which I'm about to file: we currently record all visits with type = 0 (unknown), which means we won't sync them. N.B., the patch order makes much more sense when not viewed on GitHub.
Attachment #8607244 - Flags: review?(nalexander)
Depends on: 1166084
Depends on: 1166121
No longer depends on: 1166084
Comment on attachment 8607244 [details] [review] Pull req. Comments on GH up to part 5. tl;dr: this looks pretty great. I'm a big fan of commented SQL over abstraction. Perhaps I delude myself. This needs a moderate dose of test writing, which I will consider doing myself in exchange for money. I think bnicholson or wesj should be involved in the visit tracking review.
Attachment #8607244 - Flags: review?(nalexander) → review+
Fortunately Wes reviewed the visit tracking stuff yesterday :D Swipe-to-remove is cargo-culted from bookmarks, so doesn't really need review.
Status: REOPENED → ASSIGNED
Still to do before I land this: * Unhook the tabs trigger. Still to do before I enable this: * Make sure uploading of deletions occur. I think it doesn't. * More tests and testing. * Implement a very basic scheduler to run syncs.
Merged: 78668bd Will file a bunch of follow-ups.
Status: ASSIGNED → RESOLVED
Closed: 10 years ago10 years ago
Resolution: --- → FIXED
Depends on: 1166802
Depends on: 1166806
Depends on: 1166810
Blocks: 1166812
Blocks: 1166814
No longer depends on: 1166806
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: