Search code examples
node.jsmeteorddp

Meteor.js: is the DDP implemenation suitable for an inbox-messaging apps?


I'm looking at Meteor to build a site that is comparable to a stripped-down Facebook. i.e.

  • It will have users that can connect to other users (either by 'friending' and / or 'following')
  • users can interact with content that either they or other users create/share
  • I would like to implement a 'wall' and 'news feed' like concept

The first thing you notice on the framework is how data syncs instantaneously across all clients. I'm assuming this is what the framework refers to as 'DDP'? (Please let me know if that is not correct).

Question:

  • Is this 'DDP'-like thing reliable enough to build an 'inbox' messaging functionality (i.e. Facebook messenger)?

Solution

  • DDP(roughly) is an efficient combination of some XHR techniques and web socket. And Meteor is a framework to build programs using DDP. You can check the specification.

    DDP is a protocol between a client and a server that supports two operations:

    • Remote procedure calls by the client to the server.
    • The client subscribing to a set of documents, and the server keeping the client informed about the contents of those documents as they change over time.

    If your application needs reactivity and you decides not to use Meteor, you are likely to invent a layer between client and server, which is very similar to DDP.