Hello,
I have this scenario,
I have an json schema definition in realm app on mongo cluster:
Dog{ "price": { "bsonType": "string" } }
and a realm Object on android app like so,
Dog : RealmObject{ price: String? = null }
The sync on the app is working fine upto this point.
Now, I make an destructive schema change on the realm app on mongo server i.e. I update the datatype of price to double like so:
Dog{ “price”: { “bsonType”: “double” } }
Now the sync is not working on the app and throw client error: Failed to transform received changeset: Schema mismatch.
I can solve this by updating the app’s Dog realm object but in my case there is possibility that the user does not update the app with new updated realm object code.
For that user, the sync wont work because the his app is outdated and has outdated Dog realm object schema. This is my problem.
Most of the examples and solutions I saw on the internet help with migrating after local realm object schema changes. I want to handle schema changes from backend on the app such that sync doesn’t not fail for someone with outdated realm object.