Closed Bug 1558710 Opened 4 months ago Closed 4 months ago

Remote Settings client should never try to push changes

Categories

(Firefox :: Remote Settings Client, defect, P3)

67 Branch
defect

Tracking

()

RESOLVED FIXED
Firefox 69
Tracking Status
firefox69 --- fixed

People

(Reporter: glasserc, Assigned: leplatrem)

References

Details

Attachments

(1 file)

Because of the fact that we implemented Remote Settings "on top of" the kinto.js client, we have the possibility of "updating" records on the client. If this happens, the kinto client will try to "push" these records to the server, which is impossible. This may or may not be part of bug 1558709. We seem to have had the foresight to use the SERVER_WINS sync strategy, but this only expresses what to do in case of conflicts. Probably we should forbid the client from ever even trying to push records, perhaps with additional support in the client for "read-only replica" behavior that would e.g. throw as soon as we try to "update" a record.

Maybe we should just use .pullChanges() instead of .sync(). This is where the incoming-changes hook is called etc.
Looking at the code of .sync() I don't think it would be far-fetched

Priority: -- → P3

Bugbug thinks this bug is a task, but please change it back in case of error.

Type: defect → task

Bugbug thinks this bug is a task, but please change it back in case of error.

Well Bugbug, you're wrong.

Maybe we should just use .pullChanges() instead of .sync(). T

Instead of this, having a PULL_ONLY strategy would probably give more flexibility to optimize the sync process. Even within the pullChanges() when it comes to comparing records for conflicts etc.

Type: task → defect
Pushed by mleplatre@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9e1e48c8cd7d
Make sure clients never try to push local changes r=glasserc
Status: NEW → RESOLVED
Closed: 4 months ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 69
Assignee: nobody → mathieu
You need to log in before you can comment on or make changes to this bug.