> On May 18, 2017, at 6:45 AM, Olivier Picciotto <olivi...@convertigo.com> > wrote: > > Seems that this is due the replicationID for building the pre-built database > is different from the one used to replicate it on the devices as the remote > databases URLs are different (One local and one public)
Yes. The replication checkpoint ID is based on a number of properties including the remote URL, so if you change the URL it’s a different replication. > Unfortunately, if two different devices are using the pre-built database, > again we end up with CouchBase lite checking all the documents for nothing! > This can be explained by the fact both devices are using the same > replicationID. That shouldn’t be happening. The remote docID storing the checkpoint is also affected by the local database’s UUID, but when a ‘canned’ database is installed by the Manager, it gives it a new UUID after copying it into place. …Oh, I see. In your code snippet you’re copying the database directly into CBL’s directory without going through the Manager, so it doesn’t know it’s been imported. Don’t do that. Instead call the Manager’s replaceDatabase method. —Jens -- You received this message because you are subscribed to the Google Groups "Couchbase Mobile" group. To unsubscribe from this group and stop receiving emails from it, send an email to mobile-couchbase+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/mobile-couchbase/3605890C-7755-48BB-A4B2-28E409CD484A%40couchbase.com. For more options, visit https://groups.google.com/d/optout.