Meteor-Community-Packages / ground-db

GroundDB is a thin layer providing Meteor offline database and methods

Home Page:https://atmospherejs.com/ground/db

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[FEATURE] Meteor.methods resumability

ilan-schemoul opened this issue · comments

As doc states ground:db doesn't support Meteor.methods() offline, but as ground:db is becoming more stable and more advanced, I think it could be time to add back features lost in the upgrade to V2 and THE feature lost is methods resumability. When one write in a grounded collection offline the data is sent as soon as the connection to the server is back (am I right ?), now ground:db just have to support method offline and all we be better than V1/post V1 definitively.
I think this feature is really important as it will improve the user experience A LOT, so our rich web application will be as good as natives apps ;)

Hello,
@raix Any ETA for that feature ?
Not to put you in a hurry, just to know :D

Hi @NitroBAY :)
yeah I haven't an eta on it - the issue v1 had was the the callback pattern for responses, we might want a reducer pattern for handling method responses - but thats methods only.

So if we talk about the "local" data / data added offline - this is a different story - it ties together with the concept of client-side conflict handlers, if the server wants to overwrite local only data then we have a conflict that might result in a method call to the server asking it to update / insert the data.

The latter has higher priority than the first since it's closely related to the rest of ground db

@raix @NitroBAY What about this feature being its own package? It would make it more clear what is what and there are other benefits as well, if handled well.

@StorytellerCZ I think it's a good idea to have it in its own package - that said we might need to provide an additional interface when talking about conflict resolution / collection methods (insert/update/remove)

So general ddp method resumability should be treated as a different thing than Meteor Collection ddp method calls.