JavaScript | Web and Node.js
Release Date: Sept 25, 2024
🛠️ Fixed: Missing API reference for class UpdateResult. (#14611)
Release Date: Sept 5, 2024
🛠️ Fixed: Prevent race condition that can cause attachment fetchers to fail being cleaned up. (#13961)
🛠️ Fixed: a memory leak affecting attachments downloaded using the legacy query builder API. (#13819)
🛠️ Fixed: iOS devices may fail to sync on LAN when the app is backgrounded then foregrounded. (#14150)
Release Date: Aug 28, 2024
The version 4.8.0 SDK release update brings a substantial number of improvements and new features designed to enhance your development experience and provide even more powerful tools for building robust, real-time applications.
⭐️ ➕ Added: Method exportToFile() to Logger, which exports collected logs to a compressed and JSON-encoded file on the local file system. Logs returned through this method are at DEBUG log level. This new API can be used to do forensic log gathering on a device. Logs are always collected and restricted to a fixed specific size limit to ensure they don't grow endlessly. Once the size limit has reached new logs replace the oldest logs. #11961
➕ Added: Properties peerKeyString1 and peerKeyString2 on DittoConnection replacing the deprecated properties peer1 and peer2 #12799
➕ Added: Documentation for startSync() and disableSyncWithV3() to include a recommendation for performance improvement. #13098
➕ Added: Documentation for property peerMetadata on DittoPeer to add information about how the property behaves over the lifecycle of the DittoPresenceGraph #13479
⭐️ 🔄 Changed: DQL methods now use generics for improved type safety and better IDE support. This change affects the Ditto Store's methods execute(), registerObserver(), registerObserverWithNextSignal(), its observers field, as well as the related types QueryResult, QueryResultItem, StoreObserver, StoreObservationHandler, and StoreObservationHandlerWithSignalNext. In the Sync class, the method registerSubscription() and the subscriptions field are updated, as well as the related SyncSubscription class. Type generics are added in a backwards-compatible manner by providing default types with wide bounds.
❗️🔄 Changed: Ditto.runGarbageCollection() is now an async method, which allows awaiting the completion of manual garbage collection. #8743
❗️🛠️ Fixed: Errors that occur while running manual garbage collection with Ditto.runGarbageCollection() are now thrown. #8743
🛠️ Fixed: Ditto logger is now initialized when first constructing a Ditto instance, when it used to be initialized on calling init() in browser environments and on import of the SDK in other environments. This fixes an issue where it was not possible to set the logger's verbosity level before logging began. #12719
⚠️ Deprecated: Properties peer1 and peer2 on DittoConnection, please use peerKeyString1 and peerKeyString2 instead #12799