Realm-java 7.0.0 is released

Realm Java 7.0.0 is out and ready for production deployment

NOTE: This version bumps the Realm file format to version 10. Files created with previous versions of Realm will be automatically upgraded. It is not possible to downgrade to version 9 or earlier. Only Studio 3.11 or later will be able to open the new file format.

Breaking Changes

  • [ObjectServer] Removed deprecated method SyncConfiguration.Builder.partialRealm() . Use SyncConfiguration.Builder.fullSynchronization() instead.
  • [ObjectServer] Removed deprecated methods SyncConfiguration.automatic() and SyncConfiguration.automatic(User, Uri) . Use SyncUser.getDefaultConfiguration() and SyncUser.createConfiguration(Url) .
  • [ObjectServer] Removed deprecated method ErrorCode.fromInt(int) .
  • [ObjectServer] Removed deprecated method SyncCredentials.nickname(name) and SyncCredentials.nickname(name, isAdmin) . Use SyncCredentials.usernamePassword(username, password) instead.
  • [ObjectServer] Deprecated state SyncSession.State.ERROR has been removed. Use SyncConfiguration.Builder.errorHandler(ErrorHandler) instead.
  • [ObjectServer] IncompatibleSyncedFileException is removed as it is no longer used.
  • [ObjectServer] New error codes thrown by the underlying sync layers now have proper enum mappings in . A few other errors have been renamed in order to have consistent naming. (Issue #6387)
  • RxJava Flowables and Observables are now subscribed to and unsubscribed to asynchronously on the thread holding the live Realm, instead of previously where this was done synchronously.
  • All RxJava Flowables and Observables now return frozen objects instead of live objects. This can be configured using RealmConfiguration.Builder.rxFactory(new RealmObservableFactory(true|false)) . By using frozen objects, it is possible to send RealmObjects across threads, which means that all RxJava operators should now be supported without the need to copy Realm data into unmanaged objects.
  • MIPS is not supported anymore.
  • Realm now requires minSdkVersion 16. Up from 9.
  • [ObjectServer] IncompatibleSyncedFileException is removed and no longer thrown.


  • Added Realm.freeze() , RealmObject.freeze() , RealmResults.freeze() and RealmList.freeze() . These methods will return a frozen version of the current Realm data. This data can be read from any thread without throwing an IllegalStateException , but will never change. All frozen Realms and data can be closed by calling Realm.close() on the frozen Realm, but fully closing all live Realms will also close the frozen ones. Frozen data can be queried as normal, but trying to mutate it in any way will throw an IllegalStateException . This includes all methods that attempt to refresh or add change listeners. (Issue #6590)
  • Added Realm.isFrozen() , RealmObject.isFrozen() , RealmObject.isFrozen(RealmModel) , RealmResults.isFrozen() and RealmList.isFrozen() , which returns whether or not the data is frozen.
  • Added RealmConfiguration.Builder.maxNumberOfActiveVersions(long number) . Setting this will cause Realm to throw an IllegalStateException if too many versions of the Realm data are live at the same time. Having too many versions can dramatically increase the filesize of the Realm.
  • RealmResults.asJSON() is no longer @Beta .
  • The default toString() for proxy objects now print the length of binary fields. (Issue #6767)


  • If a DynamicRealm and Realm was opened for the same file they would share transaction state by accident. The implication was that writes to a Realm would immediately show up in the DynamicRealm . This has been fixed, so now it is required to call refresh() on the other Realm or wait for normal change listeners to detect the change.


  • Realm Object Server: 3.23.1 or later.
  • Realm Studio: 3.11 or later.
  • File format: Generates Realms with format v10 (Reads and upgrades all previous formats from Realm Java 2.0 and later).
  • APIs are backwards compatible with all previous release of realm-java in the 7.x.y series.

You can read more here -

Please let us know should you find any issues

The MongoDB Realm Team

1 Like