rocicorp / replicache

Realtime Sync for Any Backend Stack
https://doc.replicache.dev
1.06k stars 38 forks source link

Use a successful push (200 OK) as a signal to try pulling again too #1020

Closed aboodman closed 2 years ago

aboodman commented 2 years ago

Related to #1019 , we can use a successful push as a signal that we might be online and to try and pull too.

Typically a successful push will result in a poke/pull pair so explicitly pulling again isn't necessary - we'd pull right away anyway. But there's an edge case where the push doesn't change anything server-side, where this would catch changes faster than waiting for the next poke.

aboodman commented 2 years ago

On second thought I think this is too much complexity for such a rare case, but definitely we should do #1019.