Replicator in Android get stuck at busy state when it goes back to online from offline

I created a demo app but was never able to reproduce the issue.

Here are all my findings so far:

  • unable to reproduce with demo app in dev cluster
  • unable to reproduce with production app in dev cluster
  • no issues with production app in production cluster when in beta test phase. ~100 unique users per day
  • Loadbalancer server, web app server, SG servers, Couchbase Server servers have plenty off compute, network and storage resources left unused
  • easily run into issue with production app in production cluster. But not reproducible. Once the issue appeared on one device it’s easy to see it on a different device, too. As far as I can tell only enough time needs to pass since the last time the SG service was last restarted. Yesterday it took around an hour. Today it ran fine for more than half a day and still does run fine.
  • issue appears when
    • app was in background and came to foreground
    • app was plugged in to wall socket and screen was kept on. After some time without using the app the issue appeared after updating a document on the device
  • Restarting the SG service fixes the issue immediately

Important to note

I have been using SG 2.6 for a while already. The described issue only appeared after most users updated to the production app with CBL 2.6/CBL 2.7 SNAPSHOT

Workaround until the issue will be fixed

I could restart the SG service via cron job every so often. Any other recommendations?

Looping in @humpback_whale and @fatmonkey45

Are you still seeing your described issues? In development only? If so are you able to reproduce it in a minimal app you could share? Or did you find a workaround and would like to share it?
I also tested @humpback_whale’s issue but could not reproduce it in production. I can edit documents on Couchbase Server dashboard. After turning airplane mode off the change is pulled down and replicator status goes back to idle.

1 Like