{"action":"created","issue":{"url":"https://api.github.com/repos/realm/realm-java/issues/1295","labels_url":"https://api.github.com/repos/realm/realm-java/issues/1295/labels{/name}","comments_url":"https://api.github.com/repos/realm/realm-java/issues/1295/comments","events_url":"https://api.github.com/repos/realm/realm-java/issues/1295/events","html_url":"https://github.com/realm/realm-java/pull/1295","id":95269690,"number":1295,"title":"Added new setDefaultConfiguration method.","user":{"login":"GavinThePacMan","id":1523414,"avatar_url":"https://avatars.githubusercontent.com/u/1523414?v=3","gravatar_id":"","url":"https://api.github.com/users/GavinThePacMan","html_url":"https://github.com/GavinThePacMan","followers_url":"https://api.github.com/users/GavinThePacMan/followers","following_url":"https://api.github.com/users/GavinThePacMan/following{/other_user}","gists_url":"https://api.github.com/users/GavinThePacMan/gists{/gist_id}","starred_url":"https://api.github.com/users/GavinThePacMan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GavinThePacMan/subscriptions","organizations_url":"https://api.github.com/users/GavinThePacMan/orgs","repos_url":"https://api.github.com/users/GavinThePacMan/repos","events_url":"https://api.github.com/users/GavinThePacMan/events{/privacy}","received_events_url":"https://api.github.com/users/GavinThePacMan/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/realm/realm-java/labels/Pending","name":"Pending","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":11,"created_at":"2015-07-15T19:18:35Z","updated_at":"2015-08-17T13:30:14Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/realm/realm-java/pulls/1295","html_url":"https://github.com/realm/realm-java/pull/1295","diff_url":"https://github.com/realm/realm-java/pull/1295.diff","patch_url":"https://github.com/realm/realm-java/pull/1295.patch"},"body":"I needed to add this to combat possible key change issues brought about by user's removing their credentials. I think this is a needed addition for anyone using keys stored in the android keystore."},"comment":{"url":"https://api.github.com/repos/realm/realm-java/issues/comments/131818533","html_url":"https://github.com/realm/realm-java/pull/1295#issuecomment-131818533","issue_url":"https://api.github.com/repos/realm/realm-java/issues/1295","id":131818533,"user":{"login":"cmelchior","id":406066,"avatar_url":"https://avatars.githubusercontent.com/u/406066?v=3","gravatar_id":"","url":"https://api.github.com/users/cmelchior","html_url":"https://github.com/cmelchior","followers_url":"https://api.github.com/users/cmelchior/followers","following_url":"https://api.github.com/users/cmelchior/following{/other_user}","gists_url":"https://api.github.com/users/cmelchior/gists{/gist_id}","starred_url":"https://api.github.com/users/cmelchior/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cmelchior/subscriptions","organizations_url":"https://api.github.com/users/cmelchior/orgs","repos_url":"https://api.github.com/users/cmelchior/repos","events_url":"https://api.github.com/users/cmelchior/events{/privacy}","received_events_url":"https://api.github.com/users/cmelchior/received_events","type":"User","site_admin":false},"created_at":"2015-08-17T13:30:14Z","updated_at":"2015-08-17T13:30:14Z","body":"Hi @GavinThePacMan \r\nSorry for the late reply. We have been hit by people going to and from vacation.\r\n\r\nI am a bit surprised that adding this method is required as we should ideally clear the configuration cache when it is no longer needed (if not, that is probably a bug). We are really restrictive about adding new constructors as we just removed a bunch of them to avoid the mental overload. So I would be really interested in seeing a unit test that showed adding this would really be needed? \r\n\r\nE.g. if you already encrypted a file with the old credentials, you would have to do something like this\r\n\r\n1) Open file with old configuration\r\n2) `Realm.writeEncryptedCopyToFile(newPassword, backup location)\r\n3) Close realm\r\n4) Delete original file\r\n5) Move backup to old location\r\n6) Open with new configuration.\r\n\r\nWhich is covered by this unit test: https://github.com/realm/realm-java/blob/master/realm/src/androidTest/java/io/realm/RealmTest.java#L1790-Lundefined\r\n\r\nChecking back in our history I think we might by accident already fixed this in this PR: https://github.com/realm/realm-java/pull/1356\r\n\r\nWhich means it should already work if you try our `0.83.0-SNAPSHOT`?\r\n\r\n\r\n\r\n\r\n \r\n\r\n\r\n\r\n\r\n"}}