"sg missing channel access" error when pushing project contents
Sometimes the initial push sync of a project's collection will reject each object with a "sg missing channel access" error. I suspect this is because the MPProject
object (which is written to the projects
collection) hasn't yet arrived and been processed by Sync Gateway by the time the contained objects arrive from the other collection.
This is a serious problem because it can mean that the project data never gets synced.
Ideas:
- Write the
MPProject
object to theproject-${project._id}
collection, so it's synced first, but this would mean that it wouldn't appear in theprojects
collection when offline. - Wait for the
projects
collection to finish pushing before pushing theproject-${project._id}
collection.
In the meantime, it would be good to do the following:
- Link to the project diagnostics page from the "Problem syncing the project data" notification.
- Add a "retry syncing all failed objects" button to the diagnostics page.
- Improve the JSON export from the diagnostics page to produce real
.manuproj
files that can be imported into a new project if needed?