I am continue with this issue since i don’t have solution
After connection reset or dropped connection PermissionManager.getPermissions() return this error:
E/REALM_SYNC: Connection: Reading failed: Connection reset by peer E/REALM_JAVA: Error in __permission: CONNECTION_RESET_BY_PEER(realm.basic_system:104): Connection reset by peer E/REALM_SYNC: Connection: Reading failed: Connection reset by peer E/REALM_JAVA: Error in __wildcardpermissions: CONNECTION_RESET_BY_PEER(realm.basic_system:104): Connection reset by peer E/REALM_SYNC: Connection: Reading failed: Connection reset by peer
Even if it network error like @cmelchior said, i think something wrong here.
If you just disable INTERNET manually for a second getPermissions() not working anymore even with new PermissionManager instance.
as i know __permission is a simple full-sync realm, and it should to work like other user’s Realms, and user’s Realms work fine after connection reset.
Call PermissionManager.getPermissions() to get the list of permissions for all Realms available to this user
PermissionManager.getPermissions() should return RealmResults
PermissionManager.getPermissions() triggers onError() with null object but with some addiotinal logs from E/REALM_SYNC
Steps to reproduce
Call PermissionManager.getPermissions() then manually disable and enable network then call PermissionManager.getPermissions() again, only after activity restart(setting configuration and connecting to realm) the PermissionManager.getPermissions() work again.
I want to mention that some connection reset happen by itself after about 5 minutes when PermissionManager.getPermissions() is called, this is happen also in the full sync TODO app example
Also does Permission/PermissionManager not support offline mode?
Realm platform cloud - standard plan
Android studio 3.4
Checked API 25/26