Swiftpack.co - Package - realm/realm-cocoa

Realm

Realm is a mobile database that runs directly inside phones, tablets or wearables. This repository holds the source code for the iOS, macOS, tvOS & watchOS versions of Realm Swift & Realm Objective-C.

Features

  • Mobile-first: Realm is the first database built from the ground up to run directly inside phones, tablets and wearables.
  • Simple: Data is directly exposed as objects and queryable by code, removing the need for ORM's riddled with performance & maintenance issues. Most of our users pick it up intuitively, getting simple apps up & running in minutes.
  • Modern: Realm supports relationships, generics, vectorization and Swift.
  • Fast: Realm is faster than even raw SQLite on common operations, while maintaining an extremely rich feature set.

Getting Started

Please see the detailed instructions in our docs to add Realm Objective-C or Realm Swift to your Xcode project.

Documentation

Realm Objective-C

The documentation can be found at realm.io/docs/objc/latest.
The API reference is located at realm.io/docs/objc/latest/api/.

Realm Swift

The documentation can be found at realm.io/docs/swift/latest.
The API reference is located at realm.io/docs/swift/latest/api/.

Getting Help

  • Need help with your code?: Look for previous questions with therealm tag on Stack Overflow or ask a new question. For general discussion that might be considered too broad for Stack Overflow, use the Realm Forums.
  • Have a bug to report? Open a GitHub issue. If possible, include the version of Realm, a full log, the Realm file, and a project that shows the issue.
  • Have a feature request? Open a GitHub issue. Tell us what the feature should do and why you want the feature.

Building Realm

In case you don't want to use the precompiled version, you can build Realm yourself from source.

Prerequisites:

  • Building Realm requires Xcode 8.x.
  • If cloning from git, submodules are required: git submodule update --init --recursive.
  • Building Realm documentation requires jazzy

Once you have all the necessary prerequisites, building Realm.framework just takes a single command: sh build.sh build. You'll need an internet connection the first time you build Realm to download the core binary.

Run sh build.sh help to see all the actions you can perform (build ios/osx, generate docs, test, etc.).

Contributing

See CONTRIBUTING.md for more details!

This project adheres to the Contributor Covenant Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to info@realm.io.

License

Realm Objective-C & Realm Swift are published under the Apache 2.0 license.
Realm Core is also published under the Apache 2.0 license and is available here.

This product is not being made available to any person located in Cuba, Iran, North Korea, Sudan, Syria or the Crimea region, or to any other person that is not eligible to receive the product under U.S. law.

Feedback

If you use Realm and are happy with it, all we ask is that you please consider sending out a tweet mentioning @realm to share your thoughts!

And if you don't like it, please let us know what you would like improved, so we can fix it!

analytics

Github

link
Stars: 13772

Dependencies

Used By

Total: 0

Releases

v4.4.0 - 2020-03-26 21:24:10

Swift 4.0 and Xcode 10.3 are now the minimum supported versions.

Enhancements

  • Allow setting the fileUrl for synchronized Realms. An appropriate local path based on the sync URL will still be used if it is not overridden. (PR #6454).
  • Add Xcode 11.4 binaries to the release package.

Fixed

  • None.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.4.

v5.0.0-beta.3 - 2020-02-27 05:44:20

Based on 4.3.2 and also includes all changes since 4.3.0.

Enhancements

  • Add support for frozen objects. Realm, Results, List and Object now have freeze() methods which return a frozen copy of the object. These objects behave similarly to creating unmanaged deep copies of the source objects. They can be read from any thread and do not update when writes are made to the Realm, but creating frozen objects does not actually copy data out of the Realm and so can be much faster and use less memory. Frozen objects cannot be mutated or observed for changes (as they never change). (PR #6427).
  • Add the isFrozen property to Realm, Results, List and Object.
  • Add Realm.Configuration.maxNumberOfActiveVersions. Each time a write transaction is performed, a new version is created inside the Realm, and then any versions which are no longer in use are cleaned up. If too many versions are kept alive while performing writes (either due to a background thread performing a long operation that doesn't let the Realm on that thread refresh, or due to holding onto frozen versions for a long time) the Realm file will grow in size, potentially to the point where it is too large to be opened. Setting this configuration option will make write transactions which would cause the live version count to exceed the limit to instead fail.

Compatibility

  • File format: Generates Realms with format v10 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • APIs are backwards compatible with all previous releases in the 5.x.y series.
  • Carthage release for Swift is built with Xcode 11.3.

Internal

  • Upgraded realm-core from v6.0.0-beta.3 to v6.0.3
  • Upgraded realm-sync from v5.0.0-beta.2 to v5.0.1

v4.3.2 - 2020-02-06 20:36:43

Enhancements

  • Similar to autoreleasepool(), realm.write() now returns the value which the block passed to it returns. Returning Void from the block is still allowed.

Fixed

  • Fix a memory leak attributed to property_copyAttributeList the first time a Realm is opened when using Realm Swift. (#6409, since 4.0.0).
  • Connecting to a realms: sync URL would crash at runtime on iOS 11 (and no other iOS versions) inside the SSL validation code. (Since 4.3.1).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.3.

Internal

  • Upgraded realm-sync from 4.9.4 to 4.9.5.

v4.3.1 - 2020-01-17 01:22:57

Enhancements

  • Reduce the encrypted page reclaimer's impact on battery life when encryption is used. (Core #3461).

Fixed

  • macOS binaries were built with the incorrect deployment target (10.14 rather than 10.9), resulting in linker warnings. (#6299, since 3.18.0).
  • An internal datastructure for List properties could be double-deleted if the last reference was released from a thread other than the one which the List was created on at the wrong time. This would typically manifest as "pthread_mutex_destroy() failed", but could also result in other kinds of crashes. (#6333).
  • Sorting on float or double properties containing NaN values had inconsistent results and would sometimes crash due to out-of-bounds memory accesses. (#6357).
  • A NOT query on a List<Object> which happened to have the objects in a different order than the underlying table would sometimes include the object immediately before an object which matches the query. (#6289, since 0.90.0).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.3.

Internal

  • Upgraded realm-core from 5.23.6 to 5.23.8.
  • Upgraded realm-sync from 4.9.0 to 4.9.4.

v5.0.0-beta.2 - 2020-01-14 22:43:30

Based on 4.3.0 and also includes all changes since 4.1.1.

Fixed

  • Fix compilation when using CocoaPods targeting iOS versions older than 11 (since 5.0.0-alpha).

Compatibility

  • File format: Generates Realms with format v10 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • APIs are backwards compatible with all previous releases in the 5.x.y series.
  • Carthage release for Swift is built with Xcode 11.3.

Internal

  • Upgraded realm-core from v6.0.0-beta.2 to v6.0.0-beta.3
  • Upgraded realm-sync from v5.0.0-beta.1 to v5.0.0-beta.2

v4.3.0 - 2019-12-20 02:54:39

Enhancements

  • Add the ability to set a custom logger function on RLMSyncManager which is called instead of the default NSLog-based logger.
  • Expose configuration options for the various types of sync connection timeouts and heartbeat intervals on RLMSyncManager.
  • Add an option to have Realm.asyncOpen() report an error if the connection times out rather than swallowing the error and attempting to reconnect until it succeeds.

Fixed

  • Fix a crash when using value(forKey:) on a LinkingObjects property (including when doing so indirectly, such as by querying on that property). (#6366, since 4.0.0).
  • Fix a rare crash in ClientHistoryImpl::integrate_server_changesets() which would only happen in Debug builds (since v3.0.0).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.3.

Internal

  • Upgraded realm-sync from 4.8.2 to 4.9.0.

v4.2.0 - 2019-12-17 01:29:12

Enhancements

  • Add -[RLMRealm fileExistsForConfiguration:]/Realm.fileExists(for:), which checks if a local Realm file exists for the given configuration.
  • Add -[RLMRealm deleteFilesForConfiguration:]/Realm.deleteFiles(for:) to delete the Realm file and all auxiliary files for the given configuration.

Fixed

  • None.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.3.

v5.0.0-beta.1 - 2019-12-14 01:11:15

NOTE: This version bumps the Realm file format to version 10. It is not possible to downgrade version 9 or earlier. Files created with older versions of Realm will be automatically upgraded. Be sure to back up any data you care about before opening it with this version of Realm as it is still in beta.

Enhancements

  • String primary keys no longer require a separate index, improving insertion and deletion performance without hurting lookup performance.
  • Reduce the encrypted page reclaimer's impact on battery life when encryption is used. (Core #3461).
  • Storing large binary blobs in Realm files no longer forces the file to be at least 8x the size of the largest blob.
  • Reduce the size of transaction logs stored inside the Realm file, reducing file size growth from large transactions.

Fixed

  • Fix an error when a table-backed Results was accessed immediately after deleting the object previously at the index being accessed (since 5.0.0-alpha.1).
  • macOS binaries were built with the incorrect deployment target (10.14 rather than 10.9), resulting in linker warnings. (#6299, since 3.18.0).
  • An internal datastructure for List properties could be double-deleted if the last reference was released from a thread other than the one which the List was created on at the wrong time. This would typically manifest as "pthread_mutex_destroy() failed", but could also result in other kinds of crashes. (#6333).
  • Sorting on float or double properties containing NaN values had inconsistent results and would sometimes crash due to out-of-bounds memory accesses. (#6357).

Breaking Changes

  • Files containing Date properties written by version of Realm prior to 1.0 can no longer be opened.
  • Files containing Any properties can no longer be opened. This property type was never documented and was deprecated in 1.0.

Known Issues

  • Changing which property of an object is the primary key in a migration will break incoming links to objects of that type.
  • Changing the primary key of an object with Data properties in a migration will crash.
  • Results notifications after deleting all objects of a type (i.e. realm.delete(realm.objects(MyType.self)) with no filter) will sometimes be incorrect.

Compatibility

  • File format: Generates Realms with format v10 (Reads and upgrades v9)
  • Realm Object Server: 3.21.0 or later.
  • APIs are backwards compatible with all previous releases in the 5.x.y series.
  • Carthage release for Swift is built with Xcode 11.3.

Internal

  • Upgraded realm-core from v6.0.0-alpha.24 to v6.0.0-beta.2
  • Upgraded realm-sync from 4.7.1-core6.5 to v5.0.0-beta.1

v4.1.1 - 2019-11-19 02:16:33

Fixed

  • The UpdatePolicy passed to realm.add() or realm.create() was not properly propagated when adding objects within a List, which could result in spurious change notifications when using .modified. (#6321, since v3.16.0)
  • Fix a rare deadlock when a Realm collection or object was observed, then refresh() was explicitly called, and then the NotificationToken from the observation was destroyed on a different thread (since 0.98.0).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.2.

v5.0.0-alpha.1 - 2019-11-18 20:58:09

NOTE: This version bumps the Realm file format to version 10. It is not possible to downgrade version 9 or earlier. Files created with older versions of Realm will be automatically upgraded. This automatic upgrade process is not yet well tested. Do not open Realm files with data you care about with this alpha version.

Breaking Changes

  • Files containing Date properties written by version of Realm prior to 1.0 can no longer be opened.
  • Files containing Any properties can no longer be opened. This property type was never documented and was deprecated in 1.0.

Compatibility

  • File format: Generates Realms with format v10 (Reads and upgrades v9)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.2.

Internal

  • Upgraded realm-core from 5.23.6 to v6.0.0-alpha.24.
  • Upgraded realm-sync from 4.8.2 to 4.7.1-core6.5.

v4.1.0 - 2019-11-13 21:40:40

Enhancements

  • Improve performance of queries over a link where the final target property has an index.
  • Restore support for storing @objc enum properties on RealmSwift.Object subclasses (broken in 4.0.0), and add support for storing them in RealmOptional properties.

Fixed

  • The sync client would fail to reconnect after failing to integrate a changeset. The bug would lead to further corruption of the client’s Realm file. (RSYNC-48, since v3.2.0).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.2.

Internal

  • Upgraded realm-core from 5.23.5 to 5.23.6.
  • Upgraded realm-sync from 4.7.11 to 4.8.2

v4.0.0 - 2019-11-08 23:03:08

Breaking Changes

  • All previously deprecated functionality has now been removed entirely.
  • The schema discovery logic for RealmSwift.Object subclasses has been rewritten in Swift. This should not have any effect on valid class definitions, but there may be types of invalid definitions which previously worked by coincidence and no longer do.
  • SyncSubscription no longer has a generic type parameter, as the type was not actually used for anything.
  • The following Swift types have changed from final class to struct:
    • AnyRealmCollection
    • LinkingObjects
    • ObjectiveCSupport
    • Realm
    • Results
    • SyncSubscription
    • ThreadSafeReference There is no intended change in semantics from this, but certain edge cases may behave differently.
  • The designated initializers defined by RLMObject and Object other than zero-argument init have been replaced with convenience initializers.
  • The implementation of the path-based permissions API has been redesigned to accomodate changes to the server. This should be mostly a transparent change, with two main exceptions:
    1. SyncPermission objects are no longer live Realm objects, and retrieving permissions gives an Array rather than Results. Getting up-to-date permissions now requires calling retrievePermissions() again rather than observing the permissions.
    2. The error codes for permissions functions have changed. Rather than a separate error type and set of error codes, permission functions now produce SyncAuthErrors.

Enhancements

  • Improve performance of initializing Realm objects with List properties.

Fixed

  • None.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.2.

v3.21.0 - 2019-11-05 01:17:36

Enhancements

  • Add prebuilt binaries for Xcode 11.2.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.2.

v3.20.0 - 2019-10-21 22:47:35

Enhancements

  • Add support for custom refresh token authentication. This allows a user to be authorized with an externally-issued refresh token when ROS is configured to recognize the external issuer as a refresh token validator. (PR #6311).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.

v3.19.1 - 2019-10-18 05:26:37

Enhancements

  • Improve performance of sync changeset integration. Transactions involving a very large number of objects and cheap operations on each object are as much as 20% faster.

Fixed

  • Fix a crash when a RLMArray/List of primitives was observed and then the containing object was deleted before the first time that the background notifier could run. (Issue #6234, since 3.0.0).
  • Remove an incorrect assertion that would cause crashes inside TableInfoCache::get_table_info(), with messages like "Assertion failed: info.object_id_index == 0 [3, 0]". (Since 3.18.0, #6268 and #6257).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.0.

Internal

  • Upgrade to REALM_SYNC_VERSION=4.7.11

v3.19.0 - 2019-09-27 23:53:15

Enhancements

  • Expose ObjectSchema.objectClass in Swift as looking up the class via NSClassFromString() can be complicated for Swift types. (PR #6244).
  • Add support for suppressing notifications using closure-based write/transaction methods. (PR #6252).

Fixed

  • IN or chained OR equals queries on an unindexed string column would fail to match some results if any of the strings were 64 bytes or longer. (Core #3386, since 3.14.2).
  • Query Based Sync subscriptions for queries involving a null timestamp were not sent to the server correctly and would match no objects. (Core #3389, since 3.17.3).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.0.

Internal

  • Upgrade to REALM_CORE_VERSION=5.23.5
  • Upgrade to REALM_SYNC_VERSION=4.7.8

v3.18.0 - 2019-09-14 03:21:30

The file format for synchronized Realms has changed. Old Realms will be automatically upgraded when they are opened. Once upgraded, the files will not be openable by older versions of Realm. The upgrade should not take a significant amount of time to run or run any risk of errors.

This does not effect non-synchronized Realms.

Enhancements

  • Improve performance of queries on Date properties (Core #3344, Core #3351).
  • Synchronized Realms are now more aggressive about trimming local history that is no longer needed. This should reduce file size growth in write-heavy workloads. (Sync #3007).
  • Add support for building Realm as an xcframework. (PR #6237).
  • Add prebuilt libraries for Xcode 11 to the release package. (PR #6248).
  • Add a prebuilt library for Catalyst/UIKit For Mac to the release package. (PR #6248).

Fixed

  • If a signal interrupted a msync() call, Realm would throw an exception and the write transaction would fail. This behavior has new been changed to retry the system call instead. (Core #3352)
  • Queries on the sum or average of an integer property would sometimes give incorrect results. (Core #3356).
  • Opening query-based synchronized Realms with a small number of subscriptions performed an unnecessary write transaction. (ObjectStore #815).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 11.0

Deprecations

  • RLMIdentityProviderNickname has been deprecated in favor of RLMIdentityProviderUsernamePassword.
  • +[RLMIdentityProvider credentialsWithNickname] has been deprecated in favor of +[RLMIdentityProvider credentialsWithUsername].
  • Sync.nickname(String, Bool) has been deprecated in favor of Sync.usernamePassword(String, String, Bool).

v3.17.3 - 2019-07-25 00:13:08

Enhancements

  • Add Xcode 10.3 binaries to the release package. Remove the Xcode 9.2 and 9.3 binaries.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.3.

v3.17.1 - 2019-07-11 01:17:57

Enhancements

  • Add support for canceling asynchronous opens using a new AsyncOpenTask returned from the asyncOpen() call. (PR #6913).
  • Importing the Realm SPM package can now be done by pinning to a version rather than a branch.

Fixed

  • Queries on a List/RLMArray which checked an indexed int property would sometimes give incorrect results. (#6154), since v3.15.0)
  • Queries involving an indexed int property had a memory leak if run multiple times. (#6186), since v3.15.0)
  • Creating a subscription with includeLinkingObjects: performed unneccesary comparisons, making it extremely slow when large numbers of objects were involved. (Core #3311, since v3.15.0)

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.17.0 - 2019-06-29 01:53:00

Enhancements

  • Add support for including Realm via Swift Package Manager. This currently requires depending on the branch "master" rather than pinning to a version (i.e. .package(url: "https://github.com/realm/realm-cocoa", .branch("master"))). (#6187).
  • Add Codable conformance to RealmOptional and List, and Encodable conformance to Results. (PR #6172).

Fixed

  • Attempting to observe an unmanaged LinkingObjects object crashed rather than throwing an approriate exception (since v0.100.0).
  • Opening an encrypted Realm could potentially report that a valid file was corrupted if the system was low on free memory. (since 3.14.0, Core #3267)
  • Calling Realm.asyncOpen() on multiple Realms at once would sometimes crash due to a FileNotFound exception being thrown on a background worker thread. (since 3.16.0, ObjectStore #806).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.16.2 - 2019-06-15 01:30:26

Enhancements

  • Add support for Xcode 11 Beta 1. Xcode betas are only supported when building from source, and not when using a prebuilt framework. (PR #6164).

Fixed

  • Using asyncOpen on query-based Realms which didn't already exist on the local device would fail with error 214. (#6178, since 3.16.0).
  • asyncOpen on query-based Realms did not wait for the server-created permission objects to be downloaded, resulting in crashes if modifications to the permissions were made before creating a subscription for the first time (since 3.0.0).
  • EINTR was not handled correctly in the notification worker, which may have resulted in inconsistent and rare assertion failures in ExternalCommitHelper::listen() when building with assertions enabled. (PR: #804, since 0.91.0).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.16.1 - 2019-06-01 00:35:52

Fixed

  • The static type passed at compile time to realm.create() was checked for a primary key rather than the actual type passed at runtime, resulting in exceptions like "''RealmSwiftObject' does not have a primary key and can not be updated'" being thrown even if the object type being created has a primary key. (since 3.16.0, #6159).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.16.0 - 2019-05-29 18:59:30

Enhancements

  • Add an option to only set the properties which have values different from the existing ones when updating an existing object with Realm.create()/-[RLMObject createOrUpdateInRealm:withValue:]. This makes notifications report only the properties which have actually changed, and improves Object Server performance by reducing the number of operations to merge. (Issue: #5970, PR: #6149).
  • Using -[RLMRealm asyncOpenWithConfiguration:callbackQueue:]/Realm.asyncOpen() to open a synchronized Realm which does not exist on the local device now uses an optimized transfer method to download the initial data for the Realm, greatly speeding up the first start time for applications which use full synchronization. This is currently not applicable to query-based synchronization. (PR: #6106).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.15.0 - 2019-05-06 23:56:53

The minimum version of Realm Object Server has been increased to 3.21.0 and attempting to connect to older versions will produce protocol mismatch errors. Realm Cloud has already been upgraded to this version, and users using that do not need to worry about this.

Enhancements

  • Add createdAt, updatedAt, expiresAt and timeToLive properties to RLMSyncSubscription/SyncSubscription. These properties will be nil for subscriptions created with older versions of Realm, but will be automatically populated for newly-created subscriptions.
  • Add support for transient subscriptions by setting the timeToLive when creating the subscription. The next time a subscription is created or updated after that time has elapsed the subscription will be automatically removed.
  • Add support for updating existing subscriptions with a new query or limit. This is done by passing update: true (in swift) or setting options.overwriteExisting = YES (in obj-c) when creating the subscription, which will make it update the existing subscription with the same name rather than failing if one already exists with that name.
  • Add an option to include the objects from RLMLinkingObjects/LinkingObjects properties in sync subscriptions, similarly to how RLMArray/List automatically pull in the contained objects.
  • Improve query performance for chains of OR conditions (or an IN condition) on an unindexed integer or string property. (Core PR #2888 and Core PR #3250).
  • Improve query performance for equality conditions on indexed integer properties. (Core PR #3272).
  • Adjust the file allocation algorithm to reduce fragmentation caused by large numbers of small blocks.
  • Improve file allocator logic to reduce fragmentation and improve commit performance after many writes. (Core PR #3278).

Fixed

  • Making a query that compares two integer properties could cause a segmentation fault on x86 (i.e. macOS only). (Core PR #3253).
  • The downloadable_bytes parameter passed to sync progress callbacks reported a value which correlated to the amount of data left to download, but not actually the number of bytes which would be downloaded.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.14.2 - 2019-04-26 00:59:50

Enhancements

  • Updating RLMSyncManager.customRequestHeaders will immediately update all currently active sync session with the new headers rather than requiring manually closing the Realm and reopening it.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.11.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.1.

v3.14.1 - 2019-04-05 20:54:36

Fixed

  • Fix "Cannot find interface declaration for 'RealmSwiftObject', superclass of 'MyRealmObjectClass'" errors when building for a simulator with Xcode 10.2 with "Install Objective-C Compatibility Header" enabled.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.11.0 or later.

v3.15.0-beta.2 - 2019-04-05 20:59:32

Enhancements

  • Improve file allocator logic to reduce fragmentation and improve commit performance after many writes. (PR #3278).

Fixed

  • None.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.1.

3.15.0-beta.1 - 2019-04-02 18:44:41

Enhancements

  • Improve query performance for chains of OR conditions (or an IN condition) on an unindexed integer or integer property. (PR #2888 and PR #3250).
  • Improve query performance for equality conditions on indexed integer properties. (PR #3272). * Adjust the file allocation algorithm to reduce fragmentation caused by large numbers of small blocks.
  • Using -[RLMRealm * asyncOpenWithConfiguration:callbackQueue:]/Realm.asyncOpen() to open a synchronized Realm which does not exist on the local device now uses an optimized transfer method to download the initial data for the Realm, greatly speeding up the first start time for applications which use full synchronization. This is currently not applicable to query-based synchronization.

Fixed

  • Making a query that compares two integer properties could cause a segmentation fault on x86 (i.e. macOS only). (PR #3253).
  • The downloadable_bytes parameter passed to sync progress callbacks reported a value which correlated to the amount of data left to download, but not actually the number of bytes which would be downloaded.

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.21.0 or later.
  • Carthage release for Swift is built with Xcode 10.1.

v3.14.0 - 2019-03-28 00:13:12

Enhancements

  • Reduce memory usage when committing write transactions.
  • Improve performance of compacting encrypted Realm files. (PR #3221).
  • Add a Xcode 10.2 build to the release package.

Fixed

  • Fix a memory leak whenever Realm makes a HTTP(s) request to the Realm Object Server (Issue #6058, since 3.8.0).
  • Fix an assertion failure when creating an object in a synchronized Realm after creating an object with a null int primary key in the same write transaction. (PR #3227).
  • Fix some new warnings when building with Xcode 10.2 beta.
  • Properly clean up sync sessions when the last Realm object using the session is deallocated while the session is explicitly suspended (since 3.9.0).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.11.0 or later.
  • Carthage release for Swift is built with Xcode 10.2.

Internal

  • Throw an exception rather than crashing with an assertion failure in more cases when opening invalid Realm files.
  • Upgrade to REALM_CORE_VERSION=5.14.0
  • Upgrade to REALM_SYNC_VERSION=3.15.1

v3.13.1 - 2019-01-03 21:23:31

Fixed

  • Fix a crash when iterating over Realm.subscriptions() using for-in. (Since 3.13.0, PR #6050).

Compatibility

  • File format: Generates Realms with format v9 (Reads and upgrades all previous formats)
  • Realm Object Server: 3.11.0 or later.