Amit K Sharma
Amit K Sharma

Reputation: 1

PouchDB sync not working in Android Device

I am using Ionic/React for hybrid mobile application development. I am using PouchDB/CouchDB for online-offline synchronization. My iOS Application is working well and syncing with remote database but the same code is not working with Android Phone / Simulator. What can be the cause? Your help is really appreciated.

const db = new PouchDB(localdb);
const remoteDatabase = new PouchDB(remotedb);

PouchDB.sync(db, remoteDatabase, {
  live: true,
  retry: true,
  timeout: false,
  batch_size: 100,
});

Upvotes: 0

Views: 345

Answers (1)

Mukopaje
Mukopaje

Reputation: 61

If you are using Android 9, and if it is working with android 6 and 7 but failing from android 8 upwards, then look into Cleartext issues. Android 9 does not play well with any HTTP calls, it needs HTTPS instead.

Upvotes: 1

Related Questions