Parameter since in pouchdb sync doesn't work

42 Views Asked by At

I use PouchDB in a web/mobile application that performs replication from a CouchDB database, and then I activate the synchronization provided by PouchDB. This synchronization, under the hood, performs bidirectional replication and triggers whenever a change occurs.

When you exit the application and re-enter, the synchronization is triggered to check for any changes that have occurred. The PouchDB synchronization method allows you to pass a parameter called "since" with a token that identifies the last change that has occurred in the CouchDB database. Alternatively, you can pass "now" to the "since" parameter to synchronize changes from that point onward, or you can omit the parameter.

The issue I'm facing is that when I pass the update_seq as the value for the since parameter, the synchronization stops working properly. Well, to be more accurate, it partially works. If I make changes in my application, they are not synchronized and remain only locally. However, if I make changes directly in CouchDB, those changes are synchronized with the application.

I hope you can help me with this issue.

0

There are 0 best solutions below