Hello,
I followed your guides and created a pre-built database by pulling it initially in the application. Then, I copied it to the Assets folder in UWP and I am trying to use that database to make the initial sync process quicker. However, in your guides you use this code block for UWP;
var assetsFolder = await Package.Current.InstalledLocation.GetFolderAsync(“Assets\seeddb.cblite2”);
var finalPath = Path.Combine(directoryPath, databaseName + “.cblite2”);
Directory.CreateDirectory(finalPath);
var destFolder = await StorageFolder.GetFolderFromPathAsync(finalPath);
var filesList = await assetsFolder.GetFilesAsync();foreach (var file in filesList) { await file.CopyAsync(destFolder); }
But you also state that unless we use any other method than Database.Copy, it will create checkpoint issues and I believe that is what I’m experiencing. As soon as a change occurs in remote, my pre-built database’s checkpoints are invalidated and it pulls the whole database all over again instead of just the changed documents.
After seeing that I also tried with Database.Copy() method but the same situation occured.
Is there anything wrong in my approach?
3 posts - 2 participants