realm-dotnet

Realm is a mobile database: a replacement for SQLite & ORMs

APACHE-2.0 License

Downloads
7.5K
Stars
1.2K
Committers
50

Bot releases are visible (Hide)

realm-dotnet - 11.7.0 Latest Release

Published by github-actions[bot] 9 months ago

11.7.0 (2024-02-05)

Enhancements

  • Automatic client reset recovery now does a better job of recovering changes when changesets were downloaded from the server after the unuploaded local changes were committed. If the local Realm happened to be fully up to date with the server prior to the client reset, automatic recovery should now always produce exactly the same state as if no client reset was involved. (Core 13.24.1)
  • Exceptions thrown during bootstrap application will now be surfaced to the user rather than terminating the program with an unhandled exception. (Core 13.25.0)
  • Allow the using >, >=, <, <= operators in Realm.Filter() queries for string constants. This is a case sensitive lexicographical comparison. Improved performance of RQL (.Filter()) queries on a non-linked string property using: >, >=, <, <=, operators and fixed behaviour that a null string should be evaluated as less than everything, previously nulls were not matched. (Core 13.26.0-14-gdf25f)

Fixed

  • Automatic client reset recovery would duplicate insertions in a list when recovering a write which made an unrecoverable change to a list (i.e. modifying or deleting a pre-existing entry), followed by a subscription change, followed by a write which added an entry to the list. (Core 13.24.0)
  • During a client reset recovery a Set of links could be missing items, or an exception could be thrown that prevents recovery. (Core 13.24.0)
  • During a client reset with recovery when recovering a move or set operation on a IList<RealmObject> or IList<RealmValue> that operated on indices that were not also added in the recovery, links to an object which had been deleted by another client while offline would be recreated by the recovering client. But the objects of these links would only have the primary key populated and all other fields would be default values. Now, instead of creating these zombie objects, the lists being recovered skip such deleted links. (Core 13.24.0)
  • Errors encountered while reapplying local changes for client reset recovery on partition-based sync Realms would result in the client reset attempt not being recorded, possibly resulting in an endless loop of attempting and failing to automatically recover the client reset. (Core 13.24.0)
  • Changesets have wrong timestamps if the local clock lags behind 2015-01-01T00:00:00Z. The sync client now throws an exception if that happens. (Core 13.24.1)
  • If the very first open of a flexible sync Realm triggered a client reset, the configuration had an initial subscriptions callback, both before and after reset callbacks, and the initial subscription callback began a read transaction without ending it (which is normally going to be the case), opening the frozen Realm for the after reset callback would trigger a BadVersion exception. (Core 13.24.1)
  • Automatic client reset recovery on flexible sync Realms would apply recovered changes in multiple write transactions, releasing the write lock in between. (Core 13.24.1)
  • Having a class name of length 57 would make client reset crash as a limit of 56 was wrongly enforced. (Core 13.24.1)
  • Fixed several causes of "decryption failed" exceptions that could happen when opening multiple encrypted Realm files in the same process while using Apple/linux and storing the Realms on an exFAT file system. (Core 13.24.1)
  • Fixed several errors that could cause a crash of the sync client. (Core 13.25.0)
  • Bad performance of initial Sync download involving many backlinks. (Core 13.25.1)
  • Explicitly bumped the minimum version of System.Net.Security to 4.3.2 as 4.3.0 has been marked as vulnerable (more details can be found in the deprecation notice on the NuGet page).
  • Handle EOPNOTSUPP when using posix_fallocate() and fallback to manually consume space. This should enable android users to open a Realm on restrictive filesystems. (Core 13.26.0)
  • Application may crash with incoming_changesets.size() != 0 when a download message is mistaken for a bootstrap message. This can happen if the synchronization session is paused and resumed at a specific time. (Core 13.26.0)
  • Fixed errors complaining about missing symbols such as __atomic_is_lock_free on ARMv7 Linux (Core 13.26.0)
  • Uploading the changesets recovered during an automatic client reset recovery may lead to 'Bad server version' errors and a new client reset. (Core 13.26.0-14-gdf25f)
  • Fixed invalid data in error reason string when registering a subscription change notification after the subscription has already failed. (Core 13.26.0-14-gdf25f)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core v13.26.0-14-gdf25f.
realm-dotnet - 11.6.1

Published by github-actions[bot] 11 months ago

11.6.1 (2023-11-17)

Fixed

  • Fixed FLX subscriptions not being sent to the server if the session was interrupted during bootstrapping. (Core 13.23.3)
  • Fixed FLX subscriptions not being sent to the server if an upload message was sent immediately after a subscription was committed but before the sync client checks for new subscriptions. (Core 13.23.3)
  • Fixed application crash with 'KeyNotFound' exception when subscriptions are marked complete after a client reset. (Core 13.23.3)
  • A crash at a very specific time during a DiscardLocal client reset on a FLX Realm could leave subscriptions in an invalid state. (Core 13.23.4)
  • Fixed an error "Invalid schema change (UPLOAD): cannot process AddColumn instruction for non-existent table" when using automatic client reset with recovery in dev mode to recover schema changes made locally while offline. (Core 13.23.4)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.23.4.
realm-dotnet - 11.6.0

Published by github-actions[bot] 12 months ago

11.6.0 (2023-11-03)

Enhancements

  • Added the App.EmailPasswordAuth.RetryCustomConfirmationAsync method to be able to run again the confirmation function on the server for a given email. (Issue #3463)

  • Added User.Changed event that can be used to notify subscribers that something about the user changed - typically this would be the user state or the access token. (Issue #3429)

  • Added support for customizing the ignore attribute applied on certain generated properties of Realm models. The configuration option is called realm.custom_ignore_attribute and can be set in a global configuration file (more information about global configuration files can be found in the .NET documentation). The Realm generator will treat this as an opaque string, that will be appended to the IgnoreDataMember and XmlIgnore attributes already applied on these members. The attributes must be fully qualified unless the namespace they reside in is added to a global usings file. For example, this is how you would add JsonIgnore from System.Text.Json:

    realm.custom_ignore_attribute = [System.Text.Json.Serialization.JsonIgnore]
    

    (Issue #2579)

  • The Realm source generator will now error out in case a collection in the model classes is assigned to a non-null value either in a property initializer or in a constructor. Realm collections are initialized internally and assigning non-null values to the property is not supported, where the null! assignment is only useful to silence nullable reference type warnings, in reality the collection will never be null. (Issue #3455)

  • Made WebSocket error logging more verbose when using AppConfiguration.UseManagedWebSockets = true. #3459

Fixed

  • Added an error that is raised when interface based Realm classes are used with a language version lower than 8.0. At the same time, removed the use of not in the generated code, so that it's compatible with a minumum C# version of 8.0. (Issue #3265)
  • Logging into a single user using multiple auth providers created a separate SyncUser per auth provider. This mostly worked, but had some quirks:
    • Sync sessions would not necessarily be associated with the specific SyncUser used to create them. As a result, querying a user for its sessions could give incorrect results, and logging one user out could close the wrong sessions.
    • Existing local synchronized Realm files created using version of Realm from August - November 2020 would sometimes not be opened correctly and would instead be redownloaded.
    • Removing one of the SyncUsers would delete all local Realm files for all SyncUsers for that user.
    • Deleting the server-side user via one of the SyncUsers left the other SyncUsers in an invalid state.
    • A SyncUser which was originally created via anonymous login and then linked to an identity would still be treated as an anonymous users and removed entirely on logout.
      (Core 13.21.0)
  • If a user was logged out while an access token refresh was in progress, the refresh completing would mark the user as logged in again and the user would be in an inconsistent state (Core 13.21.0).
  • If querying over a geospatial dataset that had some objects with a type property set to something other than 'Point' (case insensitive) an exception would have been thrown. Instead of disrupting the query, those objects are now just ignored. (Core 13.21.0)
  • Receiving a write_not_allowed error from the server would have led to a crash. (Core 13.22.0)
  • Updating subscriptions did not trigger Realm autorefreshes, sometimes resulting in async refresh hanging until another write was performed by something else. (Core 13.23.1)
  • Fix interprocess locking for concurrent realm file access resulting in a interprocess deadlock on FAT32/exFAT filesystems. (Core 13.23.1)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.20.1.
realm-dotnet - 11.5.0

Published by github-actions[bot] about 1 year ago

11.5.0 (2023-09-15)

Enhancements

  • Streamlined some of the error codes reported in SessionException. A few error codes have been combined and some have been deprecated since they are no longer reported by the server. (Issue #3295)

Fixed

  • Fixed the message of the MissingMemberException being thrown when attempting to access a non-existent property with the dynamic API. (PR #3432)
  • Fixed a Cannot marshal generic Windows Runtime types with a non Windows Runtime type as a generic type argument build error when using .NET Native. (Issue #3434, since 11.4.0)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core x.y.z.
realm-dotnet - 11.4.0

Published by github-actions[bot] about 1 year ago

11.4.0 (2023-08-16)

Enhancements

  • Added IQueryable.SubscribeAsync API as a shorthand for using SubscriptionSet.Add. It is a syntax sugar that roughly translates to:
    realm.Subscriptions.Update(() =>
    {
      realm.Subscriptions.Add(query);
    });
    
    await realm.Subscriptions.WaitForSynchronization();
    
    // This can now be expressed as
    await query.SubscribeAsync();
    
    It offers a parameter to control whether to wait every time for synchronization or just the first time a subscription is added, as well as cancellation token support. (PR #3403)
  • Added an optional cancellationToken argument to Session.WaitForDownloadAsync/WaitForUploadAsync. (PR #3403)
  • Added an optional cancellationToken argument to SubscriptionSet.WaitForSynchronization. (PR #3403)
  • Fixed a rare corruption of files on streaming format (often following compact, convert or copying to a new file). (Core 13.17.1)
  • Trying to search a full-text indexes created as a result of an additive schema change (i.e. applying the differences between the local schema and a synchronized realm's schema) could have resulted in an IllegalOperation error with the error code Column has no fulltext index. (Core 13.17.1)
  • Sync progress for DOWNLOAD messages from server state was updated wrongly. This may have resulted in an extra round-trip to the server. (Core 13.17.1)
  • Added option to use managed WebSockets (System.Net.WebSockets.ClientWebSocket) instead of Realm's built-in WebSocket client for Sync traffic. Managed WebSockets offer improved support for proxies and firewalls that require authentication. This feature is currently opt-in and can be enabled by setting AppConfiguration.UseManagedWebSockets to true. Managed WebSockets will become the default in a future version. (PR #3412).
  • Fixed an issue that would make realm.SyncSession garbage collected even when there are subscribers to realm.SyncSession.PropertyChanged.

Fixed

  • Fixed a race condition between canceling an async write transaction and closing the Realm file, which could result in an ObjectDisposedException : Safe handle has been closed being thrown. (PR #3400)
  • Fixed an issue where in the extremely rare case that an exception is thrown by Realm.RefreshAsync, that exception would have been ignored and false would have been returned. (PR #3400)
  • Fixed the nullability annotation of SubscriptionSet.Find to correctly indicate that null is returned if the subscription doesn't exist in the subscription set. (PR #3403)
  • Fixed an issue where executing Filter queries using remapped properties would only work with the native name rather than the managed one. Now both will work - e.g.:
    partial class MyModel : IRealmObject
    {
      [MapTo("Bar")]
      public int Foo { get; set; }
    }
    
    // Both of these are valid now
    realm.All<MyModel>().Filter("Foo > 5");
    realm.All<MyModel>().Filter("Bar > 5");
    
    (Issue #3149)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.17.1
realm-dotnet - 11.3.0

Published by github-actions[bot] about 1 year ago

11.3.0 (2023-07-26)

Breaking Changes

  • AppConfiguration.LocalAppName and AppConfiguration.LocalAppVersion have been deprecated and will be removed in a future version. They have never had an effect as the values supplied by the SDK was never sent to the server. (PR #3387)

Enhancements

  • Added App.BaseFilePath, App.BaseUri, and App.Id properties that return the values supplied in AppConfiguration. (PR #3385)
  • Added AppConfiguration.UseAppCache property that controls whether the App instance returned from App.Create should be cached or not. The general recommendation is to not set it (i.e. leave the default value of true), but it can be useful when writing unit tests. (Issue #3382).

Fixed

  • Fixed a Unity Editor crash when the domain is reloaded while a Realm.GetInstanceAsync operation is in progress. (Issue #3344)
  • Fixed the implementation App.Equals and App.GetHashCode to return correct results, particularly when the App instance is cached. (PR #3385)
  • Fixed an issue where building for Android on Unity would fail with "Could not analyze the user's assembly. Object reference not set to an instance of an object". (Issue #3380)
  • A GeoBox is now just a shortcut for the equivilent GeoPolygon. This provides consistent query results and error checking. (Core 13.15.2)
  • Fixed several corner cases (eg. around the poles) where invalid points matched a geoWithin query. (Core 13.15.2)
  • Fixed an error during async open and client reset if properties have been added to the schema. This fix applies to PBS to FLX migration if async open is used. (Core 13.16.1)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.17.0
realm-dotnet - 11.2.0

Published by github-actions[bot] over 1 year ago

11.2.0 (2023-07-07)

Enhancements

  • Added validation checks to the geospatial type constructors. This means that an exception will now be thrown when constructing an invalid geospatial shape rather than when using it in a query. (PR #3362)
  • Relaxed some validations when invoking IndexOf(null) on a collection of non-nullable types. Previously, this would throw an ArgumentNullException whereas now it will return -1. This is particularly useful for data-binding scenarios where the binding engine might invoke it as IndexOf(SelectedItem) which would throw an exception when SelectedItem is null. (PR #3369)
  • Changed RealmSet.IndexOf implementation to return the actual result rather than throw a NotSupportedException. The order of persisted sets is still non-deterministic, but is stable between write transactions. Again, this is mostly useful for data-binding scenarios where the set is passed as a binding context to a collection control. (PR #3369)

Fixed

  • Fixed an issue on Unity on Windows when the weaver would trigger excessive terminal windows to open. (Issue #3364
  • Fixed an issue on Unity on CI where weaving would fail with the following error: Could not analyze the user's assembly. Cannot access a closed Stream.. (Issue #3364
  • Fixed a NullReferenceException when weaving classes on Unity in batch mode. (Issue #3363)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.15.0
realm-dotnet - 11.1.2

Published by github-actions[bot] over 1 year ago

11.1.2 (2023-06-20)

Fixed

  • Fixed a namespacing issue that would cause Maui Android projects to fail to build due to 'Realm' is a namespace but is used like a type. (Issue #3351)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.15.0
realm-dotnet - 11.1.1

Published by github-actions[bot] over 1 year ago

11.1.1 (2023-06-19)

Fixed

  • Fixed a namespacing issue that would cause Unity projects to fail to build due to 'Realm' is a namespace but is used like a type. (Issue #3351)
  • Improved the warning message when adding Realm attributes on a non-persisted property. (Issue #3352)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.15.0.
realm-dotnet - 11.1.0

Published by github-actions[bot] over 1 year ago

11.1.0 (2023-06-17)

Enhancements

  • Deprecate the Realm.SourceGenerator and Realm.Fody packages. The source generation and weaver assemblies are now contained in the main Realm package. This should be a transparent change for users who only referenced the Realm package, but if you explicitly added a package reference to Realm.SourceGenerator or Realm.Fody, you should remove it. (PR #3319)
  • Automatically handle RealmObject->EmbeddedObject migrations by duplicating objects referenced by multiple parents as well as removing "orphaned" objects. (Issue #2408)
  • New notifiers can now be registered in write transactions until changes have actually been made in the write transaction. This makes it so that new notifications can be registered inside change notifications triggered by beginning a write transaction (unless a previous callback performed writes). (Core 13.10.1)
  • Partition-Based to Flexible Sync Migration for migrating a client app that uses partition based sync to use flexible sync under the hood if the server has been migrated to flexible sync is officially supported with this release. Any clients using an older version of Realm (including the original support released in Core 11.0.0) will receive a "switch to flexible sync" error message when trying to sync with the app. (Core 13.11.0)
  • Support sort/distinct based on values from a dictionary e.g. .Filter("TRUEPREDICATE SORT(meta['age'])"). (Core 13.14.0)
  • Added initial support for geospatial queries on points. (Issue #3299)
    • In this version, only queries of the form "is this point contained in this shape" (equivalent to $geoWithin in MongoDB) are supported.
    • There is no index support right now.
    • There is no dedicated type for persisted geospatial points. Instead, points should be stored as GeoJson-shaped embedded object and queries will use duck-typing to check if the shape contains the object. For convenience, here's an example embedded object that you can use in lieu of a Realm-provided dedicated type:
      public partial class Location : IEmbeddedObject
      {
        // The coordinates and type properties are mandatory but may be private.
        // You can add more fields if necessary - those will be ignored when doing
        // geospatial queries.
        [MapTo("coordinates")]
        private IList<double> Coordinates { get; } = null!;
      
        [MapTo("type")]
        private string Type { get; set; } = "Point";
      
        public double Latitude => Coordinates.Count > 1 ? Coordinates[1] : throw new Exception($"Invalid coordinate array. Expected at least 2 elements, but got: {Coordinates.Count}");
      
        public double Longitude => Coordinates.Count > 1 ? Coordinates[0] : throw new Exception($"Invalid coordinate array. Expected at least 2 elements, but got: {Coordinates.Count}");
      
        public Location(double latitude, double longitude)
        {
          // According to the GeoJson spec, longitude must come first in the
          // coordinates array.
          Coordinates.Add(longitude);
          Coordinates.Add(latitude);
        }
      }
      
      // Example usage
      public partial class Company : IRealmObject
      {
        public Location Location { get; set; }
      }
      
    • Three new shape types and one helper point type are added to allow you to check for containment:
      • GeoPoint: a building block for the other shape types - it cannot be used as a property type on your models and is only intended to construct the other shape types. It can be constructed implicitly from a value tuple of latitude and longitude:
        var point = new GeoPoint(latitude: 12.345, longitude: 67.890);
        var point = (12.345, 67.890);
        
      • GeoCircle: a shape representing a circle on a sphere constructed from a center and radius:
        var circle = new GeoCircle(center: (12.34, 56.78), radius: 10); // radius in radians
        var circle = new GeoCircle((12.34, 56.78), Distance.FromKilometers(10));
        
      • GeoBox: a shape representing a box on a sphere constructed from its bottom left and top right corners:
        var box = new GeoBox((12.34, 56.78), (15.34, 59.78));
        
      • GeoPolygon: an arbitrary polygon constructed from an outer ring and optional holes:
        var polygon = new GeoPolygon((10, 10), (20, 20), (0, 20), (10, 10)); // a triangle with no holes
        
        var outerRing = new GeoPoint[] { (10, 10), (20, 20), (0, 20), (10, 10) };
        var hole1 = new GeoPoint[] { (1, 1), (2, 2), (0, 2), (1, 1) };
        var hole2 = new GeoPoint[] { (5, 5), (6, 6), (4, 6), (5, 5) };
        
        var polygon = new GeoPolygon(outerRing, hole1, hole2); // A triangle with two smaller triangular holes
        
    • Querying can be done either via LINQ or RQL:
      var matches = realm.All<Company>().Where(c => QueryMethods.GeoWithin(c.Location, circle));
      var matches = realm.All<Company>().Filter("Location GEOWITHIN $0", circle);
      
  • Support sort/distinct based on values from a dictionary e.g. realm.All<MyModel>().Filter("TRUEPREDICATE SORT(meta['age'])"). (Core 13.14.0)
  • Fixed a potential crash when opening the realm after failing to download a fresh FLX realm during an automatic client reset. (Core 13.14.0)

Fixed

  • Fixed a fatal error (reported to the sync error handler) during client reset (or automatic PBS to FLX migration) if the reset has been triggered during an async open and the schema being applied has added new classes. (Core 13.11.0)
  • Full text search would sometimes find words where the word only matches the beginning of the search token. (Core 13.11.0)
  • We could crash when removing backlinks in cases where forward links did not have a corresponding backlink due to corruption. We now silently ignore this inconsistency in release builds, allowing the app to continue. (Core 13.12.0)
  • IDictionary<string, IRealmObject?> would expose unresolved links rather than mapping them to null. In addition to allowing invalid objects to be read from Dictionaries, this resulted in queries on Dictionaries sometimes having incorrect results. (Core 13.12.0)
  • Access token refresh for websockets was not updating the location metadata. (Core 13.13.0)
  • Using both synchronous and asynchronous transactions on the same thread or scheduler could hit the assertion failure "!realm.is_in_transaction()" if one of the callbacks for an asynchronous transaction happened to be scheduled during a synchronous transaction. (Core 13.13.0)
  • Fixed a potential crash when opening the realm after failing to download a fresh FLX realm during an automatic client reset. (Core 13.14.0)
  • Setting a property containing an embedded object to the same embedded object used to throw an exception with the text Can't link to an embedded object that is already managed. Now it is a no-op instead. (Issue #3262)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.15.0.
  • Overhauled and extended the metrics collection of the SDK to better drive future development effort. (PR #3209)
realm-dotnet - 11.0.0

Published by github-actions[bot] over 1 year ago

11.0.0 (2023-05-08)

Breaking changes

  • The error argument in NotificationCallbackDelegate and DictionaryNotificationCallbackDelegate used in *collection*.SubscribeForNotifications has been removed. It has been unused for a long time, since internal changes to the database made it impossible for errors to occur during notification callbacks. (Issue #3014)
  • Removed RealmObjectBase.GetBacklinks - instead RealmObjectBase.DynamicApi.GetBacklinksFromType should be used. (Issue #2391)
  • Removed Realm.DynamicApi.CreateObject(string, object) and replaced it with more specialized overloads:
    • RealmObjectBase.DynamicApi.CreateObject(string) can be used to create an object without a primary key.
    • RealmObjectBase.DynamicApi.CreateObject(string, string/long?/ObjectId?/Guid?) can be used to create an object with a primary key of the corresponding type.
  • The API exposed by Realm.DynamicApi no longer return dynamic, instead opting to return concrete types, such as IRealmObject, IEmbeddedObject, and so on. You can still cast the returned objects to dynamic and go through the dynamic API, but that's generally less performant than using the string-based API, such as IRealmObjectBase.DynamicApi.Get/Set, especially on AOT platforms such as iOS or Unity. (Issue #2391)
  • Removed Realm.WriteAsync(Action<Realm>) in favor of Realm.WriteAsync(Action). The new WriteAsync method introduced in 10.14.0 is more efficient and doesn't require reopening the Realm on a background thread. While not recommended, if you prefer to get the old behavior, you can write an extension method like:
    public static async Task WriteAsync(this Realm realm, Action<Realm> writeAction)
    {
      await Task.Run(() =>
      {
        using var bgRealm = Realm.GetInstance(realm.Config);
        bgRealm.Write(() =>
        {
          writeAction(bgRealm);
        });
      });
    
      await realm.RefreshAsync();
    }
    
    (PR #3234)
  • Removed InMemoryConfiguration.EncryptionKey. It was never possible to encrypt in-memory Realms and setting that property would have resulted in runtime errors. (PR #3236)
  • Removed SyncConfiguration - use PartitionSyncConfiguration or FlexibleSyncConfiguration instead. (PR #3237)
  • Removed Realm.GetSession - use Realm.SyncSession instead. (PR #3237)
  • Removed DiscardLocalResetHandler - use DiscardUnsyncedChangedHandler instead. (PR #3237)
  • Removed Session.SimulateClientReset extensions. These didn't work with automatic reset handlers and were more confusing than helpful. (PR #3237)
  • Removed AppConfiguration.CustomLogger and AppConfiguration.LogLevel - use Logger.Default and Logger.LogLevel instead. (PR #3238)
  • Removed RealmConfigurationBase.ObjectClasses - use RealmConfigurationBase.Schema instead. (PR #3240)
  • Removed ObjectSchema.IsEmbedded - use ObjectSchema.BaseType instead. (PR #3240)
  • Removed ObjectSchema.Builder.IsEmbedded - use ObjectSchema.Builder.RealmSchemaType instead. (PR #3240)
  • Removed ObjectSchema.Builder(string name, bool isEmbedded = false) - use Builder(string name, ObjectSchemaType schemaType) instead. (PR #3240)
  • Removed RealmSchema.Find - use RealmSchema.TryFindObjectSchema instead. (PR #3240)
  • Removed User.GetPushClient as it has been deprecated in Atlas App Services - see https://www.mongodb.com/docs/atlas/app-services/reference/push-notifications/. (PR #3241)
  • Removed SyncSession.Error event - use SyncConfigurationBase.OnSessionError when opening a Realm instead. (PR #3241)
  • Removed the parameterless constructor for ManualRecoveryHandler - use the one that takes a callback instead. (PR #3241)
  • RealmValue.AsString will now throw an exception if the value contains null. If you want to get a nullable string, use AsNullableString. (PR #3245)
  • RealmValue.AsData will now throw an exception if the value contains null. If you want to get a nullable byte[], use AsNullableData. (PR #3245)
  • RealmValue.AsRealmObject will now throw an exception if the value contains null. If you want to get a nullable string, use AsNullableRealmObject. (PR #3245)
  • Realm.SyncSession will now throw an error if the Realm is not opened with a PartitionSyncConfiguration or FlexibleSyncConfiguration - before it used to return null. (PR #3245)
  • Realm.Subscriptions will now throw an error if the Realm is not opened with a FlexibleSyncConfiguration - before it used to return null. (PR #3245)
  • Removed PermissionDeniedException as it was no longer possible to get it. (Issue #3272)
  • Removed some obsolete error codes from the ErrorCode enum. All codes removed were obsolete and no longer emitted by the server. (PR 3273)
  • Removed IncompatibleSyncedFileException as it was no longer possible to get it. (Issue #3167)
  • The Realms.Schema.Property API now use IndexType rather than a boolean indicating whether a property is indexed. (Issue #3281)
  • The extension methods in StringExtensions (Like, Contains) are now deprecated. Use the identical ones in QueryMethods instead - e.g. realm.All<Foo>().Where(f => f.Name.Like("Mic*l")) would need to be rewritten like realm.All<Foo>().Where(f => QueryMethods.Like(f.Name, "Mic*l")).

Enhancements

  • Added nullability annotations to the Realm assembly. Now methods returning reference types are correctly annotated to indicate whether the returned value may or may not be null. (Issue #3248)
  • Replacing a value at an index (i.e. myList[1] = someObj) will now correctly raise CollectionChange notifications with the Replace action. (Issue #2854)
  • It is now possible to change the log level at any point of the application's lifetime. (PR #3277)
  • Some log messages have been added to the Core database. Events, such as opening a Realm or committing a transaction will now be logged. (Issue #2910)
  • Added support for Full-Text search (simple term) queries. (Issue #3281)
    • To enable FTS queries on string properties, add the [Indexed(IndexType.FullText)] attribute.
    • To run LINQ queries, use QueryMethods.FullTextSearch: realm.All<Book>().Where(b => QueryMethods.FullTextSearch(b.Description, "fantasy novel")).
    • To run Filter queries, use the TEXT operator: realm.All<Book>().Filter("Description TEXT $0", "fantasy novel").
  • Performance improvement for the following queries (Core 13.8.0):
    • Significant (~75%) improvement when counting (IQueryable.Count()) the number of exact matches (with no other query conditions) on a string/int/UUID/ObjectID property that has an index. This improvement will be especially noticiable if there are a large number of results returned (duplicate values).
    • Significant (~99%) improvement when querying for an exact match on a DateTimeOffset property that has an index.
    • Significant (~99%) improvement when querying for a case insensitive match on a RealmValue property that has an index.
    • Moderate (~25%) improvement when querying for an exact match on a Boolean property that has an index.
    • Small (~5%) improvement when querying for a case insensitive match on a RealmValue property that does not have an index.
    • Moderate (~30%) improvement of equality queries on a non-indexed RealmValue.
  • Enable multiple processes to operate on an encrypted Realm simultaneously. (Core 13.9.0)
  • Improve performance of rolling back write transactions after making changes. If no notifications events are subscribed to, this is now constant time rather than taking time proportional to the number of changes to be rolled back. Rollbacks when there are notifications subscriptions are 10-20% faster. (Core 13.9.4)
  • PBS to FLX Migration for migrating a client app that uses partition based sync to use flexible sync under the hood if the server has been migrated to flexible sync. (Core 13.10.0)

Fixed

  • Fixed an issue that could cause a The specified table name is already in use exception when creating a new Realm file on multiple threads. (Issue #3302)
  • Fixed a bug that may have resulted in arrays being in different orders on different devices. Some cases of “Invalid prior_size” may be fixed too. (Core 13.7.1)
  • Fixed a crash when querying a RealmValue property with a string operator (contains/like/beginswith/endswith) or with case insensitivity. (Core 13.8.0)
  • Querying for equality of a string on an indexed RealmValue property was returning case insensitive matches. For example querying for myIndexedValue == "Foo" would incorrectly match on values of "foo" or "FOO" etc. (Core 13.8.0)
  • Adding an index to a RealmValue property on a non-empty table would crash with an assertion. (Core 13.8.0)
  • SyncSession.Stop() could hold a reference to the database open after shutting down the sync session, preventing users from being able to delete the realm. (Core 13.8.0)
  • Fix a stack overflow crash when using the query parser with long chains of AND/OR conditions. (Core 13.9.0)
  • ClientResetException.InitiateClientReset() no longer ignores the result of trying to remove a realm. This could have resulted in a client reset action being reported as successful when it actually failed on windows if the Realm was still open. (Core 13.9.0)
  • Fix a data race where if one thread committed a write transaction which increased the number of live versions above the previous highest seen during the current session at the same time as another thread began a read, the reading thread could read from a no-longer-valid memory mapping (Core 13.9.0).
  • Performing a query like {1, 2, 3, ...} IN list where the array is longer than 8 and all elements are smaller than some values in list, the program would crash (Core 13.9.4)
  • Performing a large number of queries without ever performing a write resulted in steadily increasing memory usage, some of which was never fully freed due to an unbounded cache (Core 13.9.4)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.10.0.
realm-dotnet - 10.21.1

Published by github-actions[bot] over 1 year ago

10.21.1 (2023-04-21)

Fixed

  • Fixed a crash that occurs when the server sends a PermissionDenied error. (Issue #3292)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.6.0.
realm-dotnet - 10.21.0

Published by github-actions[bot] over 1 year ago

10.21.0 (2023-03-24)

Enhancements

  • Added SyncConfiguration.CancelAsyncOperationsOnNonFatalErrors which controls whether async operations (such as Realm.GetInstanceAsync, Session.WaitForUploadAsync and so on) should throw an exception whenever a non-fatal session error occurs. (Issue #3222)
  • Added AppConfiguration.SyncTimeoutOptions which has a handful of properties that control sync timeouts, such as the connection timeout, ping-pong intervals, and others. (Issue #3223)
  • Updated some of the exceptions being thrown by the SDK to align them better with system exceptions and include more information - for example, we'll now throw ArgumentException when invalid arguments are provided rather than RealmException. (Issue #2796)
  • Added a new exception - CompensatingWriteException that contains information about the writes that have been reverted by the server due to permissions. It will be passed to the supplied FlexibleSyncConfiguration.OnSessionError callback similarly to other session errors. (Issue #3258)

Fixed

  • Changed the way the Realm SDK registers BsonSerializers. Previously, it would indiscriminately register them via BsonSerializer.RegisterSerializer, which would conflict if your app was using the MongoDB.Bson package and defined its own serializers for DateTimeOffset, decimal, or Guid. Now, registration happens via BsonSerializer.RegisterSerializationProvider, which means that the default serializers used by the SDK can be overriden by calling BsonSerializer.RegisterSerializer at any point before a serializer is instantiated or by calling BsonSerializer.RegisterSerializationProvider after creating an App/opening a Realm. (Issue #3225)
  • Creating subscriptions with queries having unicode parameters causes a server error. (Core 13.6.0)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.6.0.
  • Cancel existing builds when a new commit is pushed to a PR. (PR #3260)
realm-dotnet - 10.20.0

Published by github-actions[bot] over 1 year ago

10.20.0 (2023-02-10)

File format version bumped. Old files will be automatically upgraded but cannot be downgraded and opened with older versions of the .NET SDK.

Breaking Changes

  • User.GetPushClient has been deprecated as it will be disabled soon on the server. (Issue #3073)

Enhancements

  • The realm file will be shrunk if the larger file size is no longer needed. (Core 13.0.0)

  • Most of the file growth caused by version pinning is eliminated. (Core 13.0.0)

  • Improve performance of acquiring read locks when a read lock for that version is already held. This speeds up many operations related to change notifications, and particularly refreshing a Realm which has change notifiers registered. (Core 13.2.0)

  • Upgrade OpenSSL from 1.1.1n to 3.0.7. (Core 13.2.0)

  • Converting flexible sync realms to bundled and local realms is now supported (Core 13.2.0)

  • Add support for nested classes for source generated classes. (Issue #3031)

  • Enhanced support for nullable reference types in the model definition for source generated classes. This allows to use realm models as usual when nullable context is active, and removes the need to use of the Required attribute to indicate required properties, as this information will be inferred directly from the nullability status. There are some considerations regarding the nullability of properties that link to realm object:

    • Properties that link to a single realm object are inherently nullable, and thus the type must be defined as nullable.
    • List, Sets and Backlinks cannot contain null objects, and thus the type parameter must be non-nullable.
    • Dictionaries can contain null values, and thus the type parameter must be nullable.

    Defining the properties with a different nullability annotation than what has been outlined here will raise a diagnostic error. For instance:

    public partial class Person: IRealmObject
    {
        //Single values
        public Dog? MyDog { get; set; } //Correct
    
        public Dog MyDog { get; set; } //Error
    
        //List
        public IList<Dog> MyDogs { get; } //Correct
    
        public IList<Dog?> MyDogs { get; } //Error
    
        //Set
        public ISet<Dog> MyDogs { get; } //Correct
    
        public ISet<Dog?> MyDogs { get; } //Error
    
        //Dictionary
        public IDictionary<string, Dog?> MyDogs { get; } //Correct
    
        public IDictionary<string, Dog> MyDogs { get; } //Error
    
        //Backlink
        [Realms.Backlink("...")]
        public IQueryable<Dog> MyDogs { get; } //Correct
    
        [Realms.Backlink("...")]
        public IQueryable<Dog?> MyDogs { get; } //Error
    }
    

    We realise that some developers would still prefer to have more freedom in the nullability annotation of such properties, and it is possible to do so by setting realm.ignore_objects_nullability = true in a global configuration file (more information about global configuration files can be found in the .NET documentation). If this is enabled, all the previous properties will be considered valid, and the nullability annotations for properties linking to objects will be ignored.

  • Improved performance of PropertyChanged and CollectionChanged notifications. (Issue #3112)

  • Added support for tvOS in Xamarin/MAUI and Unity applications. (Issue #3161)

  • Improve the performance of Realm.Freeze(). (Core 13.3.0)

Fixed

  • ISet<RealmValue> consider string and binary data equivalent. This could cause the client to be inconsistent with the server if a string and some binary data with equivalent content was inserted from Atlas. (Core 13.0.0)
  • Fixed wrong assertion on query error that could result in a crash. (Core 13.1.0)
  • Fixed an issue preventing opening an encrypted file on a device with a page size bigger than the one on which the file was produced. (Core 13.1.1)
  • Fixed possible segfault in sync client where async callback was using object after being deallocated (Core 13.2.0)
  • Fixed crash when using client reset with recovery and flexible sync with a single subscription (Core 13.2.0)
  • Added a more descriptive error message when a model's property is unsupported. It'll now suggest that the target type may need to inherit from RealmObject. (Issue #3162)
  • Disposing a Realm instance while an active transaction is running will now correctly roll back the transaction. (Issue #2924)
  • Fixed an issue that would cause PropertyChanged notifications to be delivered for collection properties when the content of the collection was modified even if the collection itself was not replaced. (Issue #3112)
  • Fixed an issue where weaving assemblies on Unity could result in System.InvalidOperationException. (Issue #3199)
  • Session.Stop will now correctly keep the session stopped until Session.Start is called. Previously, there were a number of circumstances that could cause the session to be resumed, even if not explicitly requested. (Core 13.3.0)
  • When client reset with recovery is used and the recovery does not actually result in any new local commits, the sync client may have gotten stuck in a cycle with a A fatal error occured during client reset: 'A previous 'Recovery' mode reset from did not succeed, giving up on 'Recovery' mode to prevent a cycle' error message. (Core 13.3.0)
  • Fixed diverging history in flexible sync if writes occur during bootstrap to objects that just came into view. (Core 13.3.0)
  • Fix several data races when opening cached frozen Realms. New frozen Realms were added to the cache and the lock released before they were fully initialized, resulting in races if they were immediately read from the cache on another thread. (Core 13.3.0)
  • If a client reset w/recovery or discard local is interrupted while the "fresh" realm is being downloaded, the sync client may crash with a MultpleSyncAgents exception. (Core 13.3.0)
  • Changesets from the server sent during FLX bootstrapping that are larger than 16MB can cause the sync client to crash with a LogicError. (Core 13.3.0)
  • Sharing Realm files between a Catalyst app and Realm Studio did not properly synchronize access to the Realm file. (Core 13.4.0)

Compatibility

  • Realm Studio: 13.0.0 or later.

Internal

  • Using Core 13.4.0.
  • Updated DynamicRealmObjectHelper.TryGetPrimaryKeyValue not to use reflection. (Issue #3166)
  • Fixed UWP tests workflow when running a debug build. (Issue #3030)
realm-dotnet - 10.19.0

Published by github-actions[bot] almost 2 years ago

10.19.0 (2023-01-06)

Enhancements

  • Removed redundant serialization/deserialization of arguments in CallAsync. (Issue #3079)

  • Added a field Transaction.State which describes the current state of the transaction. (Issue #2551)

  • Improved error message when null is passed as argument to params for EmailPasswordAuth.CallResetPasswordFunctionAsync. (Issue #3011)

  • Removed backing fields of generated classes' properties which should provide minor improvements to memory used by Realm Objects (Issue #2647)

  • Added two extension methods on IDictionary to get an IQueryable collection wrapping the dictionary's values:

    • dictionary.AsRealmQueryable() allows you to get a IQueryable<T> from IDictionary<string, T> that can be then treated as a regular queryable collection and filtered/ordered with LINQ or Filter(string).
    • dictionary.Filter(query, arguments) will filter the list and return a filtered collection of dictionary's values. It is roughly equivalent to dictionary.AsRealmQueryable().Filter(query, arguments).

    The resulting queryable collection will behave identically to the results obtained by calling realm.All<T>(), i.e. it will emit notifications when it changes and automatically update itself. (Issue #2647)

  • Improve performance of client reset with automatic recovery and converting top-level tables into embedded tables. (Core upgrade)

  • Flexible sync will now wait for the server to have sent all pending history after a bootstrap before marking a subscription as Complete. (Core upgrade)

  • Slightly improve performance of Realm.RemoveAll() which removes all objects from an open Realm database. (Issue #2233)

  • Improve error messages when not setting a BaseFilePath for realm or app configuration. (Issue 2863)

  • Added diagnostic error for nested classes used with the source generator syntax, as they are not yet supported. (Issue #3130)

  • Added IList implementation to all Realm collections to allow for UWP ListView databinding. (Issue #1759)

Fixed

  • Fixed issue where Realm parameters' initialization would get run twice, resulting in unexpected behavior.
  • Prevented IEmbeddedObjects and IAsymmetricObjects from being used as RealmValues when added to a realm, and displaying more meaningful error messages.
  • Fix a use-after-free if the last external reference to an encrypted Realm was closed between when a client reset error was received and when the download of the new Realm began. (Core upgrade)
  • Fixed an assertion failure during client reset with recovery when recovering a list operation on an embedded object that has a link column in the path prefix to the list from the top level object. (Core upgrade)
  • Opening an unencrypted file with an encryption key would sometimes report a misleading error message that indicated that the problem was something other than a decryption failure. (Core upgrade)
  • Fix a rare deadlock which could occur when closing a synchronized Realm immediately after committing a write transaction when the sync worker thread has also just finished processing a changeset from the server. (Core upgrade)
  • Fix a race condition which could result in "operation cancelled" errors being delivered to async open callbacks rather than the actual sync error which caused things to fail. (Core upgrade)
  • Bootstraps will not be applied in a single write transaction - they will be applied 1MB of changesets at a time, or as configured by the SDK. (Core upgrade)
  • Fix database corruption and encryption issues on apple platforms. (Core upgrade)
  • Added fully qualified names for source generated files, to avoid naming collisions. (Issue #3099
  • Fixed an issue that would cause an exception when using unmanaged objects in bindings (Issue #3094)
  • Fixed an issue where fetching a user's profile while the user logs out would result in an assertion failure. (Core upgrade)
  • Removed the ".tmp_compaction_space" file being left over after compacting a Realm on Windows. (Core upgrade)
  • Fixed a crash that would occur if you close a synchronized Realm while waiting for SubscriptionSet.WaitForSynchronizationAsync. (Issue #2952)
  • Avoid calling the setter on UI-bound properties in case the new value of the property is the same as the current one. This avoids some issue with MAUI, that seems to be calling the setter of bound properties unnecessarily when CollectionView/ListView are shown on screen. This is problematic if the object does not belong to the current user's permissions, as it will cause a compensanting write. In some limited cases this could cause an error loop (verified on iOS) when recycling of cells is involved. (Issue #3128)
  • Fixes an issue with where the source generator will not add the namespace for types used in properties' initializers. (Issue #3135)
  • Fixed an issue that would prevent Realm from working correctly in Unity applications that have Domain Reloading turned off. (Issue #2898)
  • Fixed a bug when using string.Contains in .NET 2.1 or later where the search string is not a literal. (Issue #3134)
  • Added [Obsolete] notice for a few ErrorCode enum members that are no longer in use. (Issue #3155

Compatibility

  • Realm Studio: 12.0.0 or later.

Internal

  • Using Core 12.13.0.
  • Replaced Realm.RefreshAsync with a native implementation. (PR #2995)
realm-dotnet - 10.18.0

Published by github-actions[bot] almost 2 years ago

10.18.0 (2022-11-02)

Enhancements

  • Introduced Realm.SourceGenerator, a Source Generator that can generate Realm model classes. This is part of our ongoing effort to modernize the Realm library, and will allow to introduce certain language level features easier in the future.
    In order to use the source generation the model classes need to be declared implementing one of the base interfaces (IRealmObject, IEmbeddedObject or IAsymmetricObject) and be declared partial. For example:

    public partial class Person: IRealmObject
    {
        public int Age { get; set; }
    
        public string Name { get; set; }  
    
        public PhoneNumber Phone { get; set; }
    }
    
    public partial class PhoneNumber: IEmbeddedObject
    {
        public string Number { get; set; }
    
        public string Prefix { get; set; }  
    }
    

    The source generator will then take care of adding the full implementation for the interfaces.

    Most of the time converting the "classic" Realm model classes (classes derived from RealmObject, EmbeddedObject or AsymmetricObject) to use the new source generation means just defining the class as partial and switching out the base class for the corresponding interface implementation.
    The classic Realm model definition will still be supported, but will be phased out in the future.

    Please note that the source generator is still in beta, so let us know if you experience any issue while using them.
    Some additional notes:

    • OnManaged and OnPropertyChanged are now partial methods.
    • Inheritance is not supported, so the Realm models cannot derive from any other class.
    • Nested classes are not supported.

Fixed

  • Fixed a NullReferenceException being thrown when subscribing to PropertyChanged notifications on a Session instance that is then garbage collected prior to unsubscribing. (PR #3061)
  • Removed bitcode support from the iOS binary as it's no longer accepted for App Store submissions. (Issue #3059)
  • Slightly increased performance and reduced allocations when creating an enumerator for frozen collections (Issue #2815).

Compatibility

  • Realm Studio: 11.0.0 or later.

Internal

  • Using Core 12.9.0.
  • Added workflow to automatically assign users to issues and PRs. (PR #3069)
  • Added workflow to validate changelog has been updated. (PR #3069)
realm-dotnet - 10.17.0

Published by github-actions[bot] about 2 years ago

10.17.0 (2022-10-06)

Enhancements

  • Prioritize integration of local changes over remote changes - shorten the time users may have to wait when committing local changes. Stop storing downloaded changesets in history. (Core upgrade)
  • Greatly improve the performance of sorting or distincting a Dictionary's keys or values. The most expensive operation is now performed O(log N) rather than O(N log N) times, and large Dictionaries can see upwards of 99% reduction in time to sort. (Core upgrade)
  • Seamlessly handle migrating an App Services application deployment model. (Core upgrade)

Fixed

  • Fix a use-after-free when a sync session is closed and the app is destroyed at the same time. (Core upgrade)
  • Fixed a NullReferenceException occurring in RealmObjectBase's finalizer whenever an exception is thrown before the object gets initialized. (Issue #3045)

Compatibility

  • Realm Studio: 11.0.0 or later.

Internal

  • Using Core 12.9.0
realm-dotnet - 10.16.0

Published by github-actions[bot] about 2 years ago

10.16.0 (2022-10-03)

Enhancements

  • Introduced AsymmetricObject intended for write-heavy workloads, where high performance is generally important. This new object:

    1. syncs data unidirectionaly, from the clients to the server
    2. can't be queried, deleted, or modified once added to the Realm
    3. is only usable with flexible sync
    4. can't be the receiveing end of any type of relationship
    5. can contain EmbeddedObjects but cannot link to RealmObject or AsymmetricObject.

    In the same write transaction, it is legal to add AsymmetricObjects and RealmObjects

    class Measurement : AsymmetricObject
    {
        [PrimaryKey, MapTo("_id")]
        public Guid Id { get; private set; } = Guid.NewGuid();
    
        public double Value { get; set; }
    
        public DataTimeOffset Timestamp { get; private set; } = DateTimeOffset.UtcNow;
    }
    
    class Person : RealmObject
    {
        //............
    }
    
    //.....
    
    var measurement = new Measurement
    {
      Value = 9.876
    };
    
    realm.Write(() =>
    {
        realm.Add(measurement);
    
        realm.Add(new Person());
    });
    
    _ = asymmetricObject.Value;   // runtime error
    _ = realm.All<Measurement>(); // compile time error
    
  • Added two client reset handlers, RecoverUnsyncedChangesHandler and RecoverOrDiscardUnsyncedChangesHandler, that try to automatically merge the unsynced local changes with the remote ones in the event of a client reset. Specifically with RecoverOrDiscardUnsyncedChangesHandler, you can fallback to the discard local strategy in case the automatic merge can't be performed as per your server's rules. These new two stragegies simplify even more the handling of client reset events when compared to DiscardUnsyncedChangesHandler.RecoverOrDiscardUnsyncedChangesHandler is going to be the default from now on. An example is as follows

  • Added two client reset handlers, RecoverUnsyncedChangesHandler and RecoverOrDiscardUnsyncedChangesHandler, that try to automatically merge the unsynced local changes with the remote ones in the event of a client reset. Specifically with RecoverOrDiscardUnsyncedChangesHandler, you can fallback to the discard unsynced strategy in case the automatic merge can't be performed as per your server's rules. These new two stragegies simplify even more the handling of client reset events when compared to DiscardUnsyncedChangesHandler.RecoverOrDiscardUnsyncedChangesHandler is going to be the default from now on. More info on the aforementioned strategies can be found in our docs page. An example usage of one of the new handler is as follows:

    var conf = new PartitionSyncConfiguration(partition, user)
    {
      ClientResetHandler = new RecoverOrDiscardUnsyncedChangesHandler
      {
        // As always, the following callbacks are optional
    
        OnBeforeReset = (beforeFrozen) =>
        {
          // executed right before a client reset is about to happen
        },
        OnAfterRecovery = (beforeFrozen, after) =>
        {
          // executed right after an automatic recovery from a client reset has completed
        },
        OnAfterDiscard = (beforeFrozen, after) =>
        {
          // executed after an automatic recovery from a client reset has failed but the DiscardUnsyncedChanges fallback has completed
        },
        ManualResetFallback = (session, err) =>
        {
          // handle the reset manually
        }
      }
    };
    

    (PR #2745)

  • Introducing string query support for constant list expressions such as realm.All<Car>().Filter("Color IN {'blue', 'orange'}"). This also includes general query support for list vs list matching such as realm.All<Car>().Filter("NONE Features IN {'ABS', 'Seat Heating'}"). (Core upgrade)

  • Improve performance when a new Realm file connects to the server for the first time, especially when significant amounts of data has been written while offline. (Core upgrade)

  • Shift more of the work done on the sync worker thread out of the write transaction used to apply server changes, reducing how long it blocks other threads from writing. (Core upgrade)

  • Improve the performance of the sync changeset parser, which speeds up applying changesets from the server. (Core upgrade)

Fixed

  • Added a more meaningful error message whenever a project doesn't have [TargetFramework] defined. (Issue #2843)
  • Opening a read-only Realm for the first time with a SyncConfiguration did not set the schema version, which could lead to m_schema_version != ObjectStore::NotVersioned assertion failures. (Core upgrade)
  • Upload completion callbacks (i.e. Session.WaitForUploadAsync) may have called before the download message that completed them was fully integrated. (Core upgrade)
  • Fixed an exception "fcntl() with F_BARRIERFSYNC failed: Inappropriate ioctl for device" when running with MacOS on an exFAT drive. (Core upgrade)
  • Syncing of a Decimal128 with big significand could result in a crash. (Core upgrade)
  • Realm.Refresh() did not actually advance to the latest version in some cases. If there was a version newer than the current version which did not require blocking it would advance to that instead, contrary to the documented behavior. (Core upgrade)
  • Several issues around notifications were fixed. (Core upgrade)
    • Fix a data race on RealmCoordinator::m_sync_session which could occur if multiple threads performed the initial open of a Realm at once.
    • If a SyncSession outlived the parent Realm and then was adopted by a new Realm for the same file, other processes would not get notified for sync writes on that file.
    • Fix one cause of QoS inversion warnings when performing writes on the main thread on Apple platforms. Waiting for async notifications to be ready is now done in a QoS-aware ways.
  • If you set a subscription on a link in flexible sync, the server would not know how to handle it (#5409, since v11.6.1)
  • If a case insensitive query searched for a string including an 4-byte UTF8 character, the program would crash. (Core upgrade)
  • Added validation to prevent adding a removed object using Realm.Add. (Issue #3020)

Compatibility

  • Realm Studio: 12.0.0 or later.

Internal

  • Using Core 12.7.0.
realm-dotnet - 10.15.1

Published by github-actions[bot] about 2 years ago

10.15.1 (2022-08-08)

Fixed

  • Fixed an issue introduced in 10.15.0 that would prevent non-anonoymous user authentication against Atlas App Services. (Issue #2987)
  • Added override to User.ToString() that outputs the user id and provider. (PR #2988)
  • Added == and != operator overloads to User that matches the behavior of User.Equals. (PR #2988)

Compatibility

  • Realm Studio: 12.0.0 or later.

Internal

  • Using Core x.y.z.
realm-dotnet - 10.15.0

Published by github-actions[bot] about 2 years ago

10.15.0 (2022-08-05)

Enhancements

  • Preview support for .NET 6 with Mac Catalyst and MAUI. (PR #2959)
  • Reduce use of memory mappings and virtual address space (Core upgrade)

Fixed

  • Fix a data race when opening a flexible sync Realm (Core upgrade).
  • Fixed a missing backlink removal when setting a RealmValue from a RealmObject to null or any other non-RealmObject value. Users may have seen exception of "key not found" or assertion failures such as mixed.hpp:165: [realm-core-12.1.0] Assertion failed: m_type when removing the destination object. (Core upgrade)
  • Fixed an issue on Windows that would cause high CPU usage by the sync client when there are no active sync sessions. (Core upgrade)
  • Improved performance of sync clients during integration of changesets with many small strings (totalling > 1024 bytes per changeset) on iOS 14, and devices which have restrictive or fragmented memory. (Core upgrade)
  • Fix exception when decoding interned strings in realm-apply-to-state tool. (Core upgrade)
  • Fix a data race when committing a transaction while multiple threads are waiting for the write lock on platforms using emulated interprocess condition variables (most platforms other than non-Android Linux). (Core upgrade)
  • Fix some cases of running out of virtual address space (seen/reported as mmap failures) (Core upgrade)
  • Decimal128 values with more than 110 significant bits were not synchronized correctly with the server (Core upgrade)

Compatibility

  • Realm Studio: 11.0.0 or later.

Internal

  • Using Core 12.4.0.