amplify-swift/Amplify/Categories/Predictions/Internal
Tim Schmelter 67a1c61c5b
fix: Fix data store mutation when restoring network (#1345)
Fixes an issue in DataStore where it dropped consecutive updates to a model if
received while the network was not connected. As part of this fix, we
simplified the OutgoingMutationQueue state machine and cleaned up potential
race conditions in state synchronization between RemoteSyncEngine and
OutgoingMutationQueue.

- fix: Fix data races in MutationRetryNotifier encountered in some test
  situations. It's unclear whether this would be encountered in production
  since the production model includes additional queue protections.

- fix: Fix retain cycles in RemoteSyncEngine

- fix: RemoteSyncEngine now correctly sets up publisher notifications for
  custom reachability publishers

- test: Change SyncEngineTestBase reachabilityPublisher to be
  CurrentValueSubject

- test: DataStore sync tests can now specify an on-disk SQLite file rather than
  only an in-memory SQLite database to back the DataStore.

- test: API category can now specify a custom reachability publisher

- test: fix Amplify.reset(). This includes explicitly declaring Resettable
  conformance for a few types that were missing it, protecting `Logger` with an
  AtomicValue since it is used during the actual reset() flow, and adding
  verbose logging to reset flows to help identify race conditions or deadlocks
  in future. Amplify.reset() is also now synchronous, although Resettable.reset()
  still accepts a callback.

- test: Overall DataStore test stability fixes
2021-08-03 12:07:38 -07:00
..
DefaultNetworkPolicy.swift chore: Remove copyright year from .swift, .h, .plist files (#1008) 2021-01-06 11:44:40 -08:00
PredictionsCategory+CategoryConfigurable.swift chore: Remove copyright year from .swift, .h, .plist files (#1008) 2021-01-06 11:44:40 -08:00
PredictionsCategory+Resettable.swift fix: Fix data store mutation when restoring network (#1345) 2021-08-03 12:07:38 -07:00