- After all data is synced, use terminal commands to pull cblite2 folders and copy them to external storage so I can access them outside of the app context.
- After a reinstall of our app, the code initializes couchbase
- Sets the DatabaseConfiguration directory to a new directory in external storage
- Calls Database.copy, passing in the location of where I had pulled the cblite2 folders to
- Create new Database using the configuration and then creates indexes.
Steps 2-5 should all happen on a non-UI thread. I have try catch blocks around steps 4 and 5 and only 5 is throwing any exception (that the data is corrupt).
If there’s any other info I can provide, please let me know. Preemptively, I’ll try generating a sanitized database that I can share with you guys.