You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -1157,6 +1158,26 @@ Enable detailed logging during development:
1157
1158
-Syncoperations
1158
1159
-Changecounts
1159
1160
1161
+
## ⚠️ KnownIssues&Improvements
1162
+
1163
+
### ReactiveQueries&WriteConnectionContention
1164
+
1165
+
**Issue:**`useSqliteSyncQuery`uses`writeDb`withop-sqlite's `reactiveExecute` to ensure queries see sync changes immediately. However, when data changes frequently (e.g., during active sync), the write connection can become a bottleneck.
1166
+
1167
+
**Potentialimprovement:**Have`cloudsync_network_sync()`returnthelistofupdatedtables. Thiswouldallowreactivequeriestouse`readDb`instead, with manual invalidation when sync completes for specific tables. Trade-off: manualinvalidationlogicvs. op-sqlite's built-in `reactiveExecute`.
1168
+
1169
+
### OptimisticUpdates&SyncBlocking
1170
+
1171
+
**Issue:**Withpushnotifications, sync can be triggered frequently. Since sync operations use `writeDb`, a user writing to the local database at the same time may experience delayed UI updates while waiting for the sync transaction to complete.
1172
+
1173
+
**Potential improvement:**ImplementoptimisticupdateswherelocalwritesupdatetheUIimmediately, independent of sync status. This requires careful handling of conflict resolution when sync completes.
1174
+
1175
+
### First Install Empty State
1176
+
1177
+
**Issue:**Onfirstappinstall, the initial sync may not return changes immediately (servermayneedtimetopreparedata). The app stops showing the loader and displays empty content, then shows the actual data on the second sync interval.
1178
+
1179
+
**Potential improvement:**Keepshowingaloaderuntilthefirstsuccessfulsyncwithdata, or until a timeout since there might not be any data to fetch
1180
+
1160
1181
## 📖 Examples
1161
1182
1162
1183
Check out the [examples](./examples) directory for complete working examples:
0 commit comments