3 ms·
One thing that is not easy to do with a relational model, is offline synchronization for high-availability on mobile devices. The document model was built for t
by jchrisa 13y ago
One thing that is not easy to do with a relational model, is offline synchronization for high-availability on mobile devices. The document model was built for this, I find it hilarious that so few of the NoSQL databases are taking advantage of the latent capability.
Try out Couchbase Mobile http://mobile.couchbase.com http://mobile.couchbase.com and compare it to best of breed relational sync.
- SchizoDuckie 13y agoIt is not hard at all. people just hadn't built as much of the tools for it. Which also confuses me because we now have package managers that run on package managers. My own little WebSQL Object/Relation mapping library uses promises to get away from callback hell, and it's a pure joy to work with. It handles creating tables and inserting fixtures before the first connect promise is returned, so that you don't have to worry about the setup process and your data being available. Creating and inserting entities is as easy as > var P = new Presentation(); > P.set('name', 'test'); > P.Persist().then(function(result) { console.log('Done!') }); http://schizoduckie.github.io/CreateReadUpdateDelete.js/demo/ http://schizoduckie.github.io/CreateReadUpdateDelete.js/demo... I'm using it extensively in my Chrome plugin, and it runs on 10.000+ clients right now. Real world offline synchronisation example right here: https://github.com/SchizoDuckie/DuckieTV/blob/angular/js/services/MigrationService.js#L52 https://github.com/SchizoDuckie/DuckieTV/blob/angular/js/ser...
- frik 13y agoNice work. This would be the way to go. Sadly one cannot use it everywhere as WebSQL is not implemented in Firefox nor IE :( The good thing is WebSQL works also great on mobile devices.
- mamcx 13y agoI have think about use it, but still it fail if the data is relational. I have a invoice app, and none of the NOSQL I have evaluated guarantee the order of the updates or have atomic updates (need both). Is not fun if a invoice update partially or the related tables get out of sync. In the other hand, I'm stuck in how sync with a relational model :( So, it sync well and broke my relations and transactions or it sync hard but keep my data correct.