

Introduction to WAMP, a Protocol Enabling PUB/SUB and RPC over Websocket - sametmax
http://fr.slideshare.net/sametmax/intro-wamp

======
WhitneyLand
Proposed benefits:

    
    
      -  Direct browser to browser communication.
    

Except it’s not, because everything goes through a router, so how’s that
different from using an HTTP server in terms of moving parts?

    
    
      -  Can work outside of browsers.
    

So can HTTP.

    
    
      -  Allows independent microservices.
    

Again, so does HTTP.

    
    
      -  Has push and pub/sub.
    

Ok, but so does anything based on websockets, I don’t see how that’s an
argument for this protocol.

To extend that reasoning, there are many things sockets may be better for but
I'd like to hear the arguments specifically in support of WAMP.

~~~
amirouche
WAMP is interesting to scale WebSocket (WS) application, going from 1
websocket procesus to several. You can do the same with Redis or else.

Otherwise said it allows to create clustered websocket (WS) applications.

E.g. two clients are connected to the same web chat room but via different WS
servers, WAMP will allow to forward messages happening in one websocket
server/processus to the other, otherwise their would be the equivalent of an
IRC net split. You can do that with Redis too, but with WAMP “it just
works”(tm).

\- WS doesn't support natively RPC as «function call + return value»

\- PUB/SUB is also nice to have, especially since it's cluster-aware.

> \- Direct browser to browser communication.

There is a router and that is all, you don't have to setup your own (cluster
aware) dispatch logic.

edit: this might be helpful [http://wamp.ws/why/](http://wamp.ws/why/)

------
imslavko
WAMP came up on Meteor's mailing list some time ago. One would compare it with
Meteor's own pub/sub and rpc protocol called DDP
([https://www.meteor.com/ddp](https://www.meteor.com/ddp)).

DDP has clients in Objective-C, Java, Python and some other major languages,
too:
[http://www.meteorpedia.com/read/DDP_Clients](http://www.meteorpedia.com/read/DDP_Clients)

[https://groups.google.com/forum/#!searchin/meteor-
talk/wamp/...](https://groups.google.com/forum/#!searchin/meteor-
talk/wamp/meteor-talk/9-pTabvQeHw/XUG9t6qMbtcJ)

------
bbody
I have used WAMP 1.0 for a few projects and converted some Play framework code
to pure Java EE7 code. However I haven't used it in any of my recent projects
because of support, I like losing the HTTP header, saves a fair bit of
traffic.

------
sametmax
he de facto open source WAMP router, crossbar.io, is written with Twisted,
Python. For now it's Python 2.7 only, but Autobahn Python, the Python client,
works with Twisted or asyncio (Python 3)

The cool thing is that it's an open standard registered at IANA
([https://www.iana.org/assignments/websocket/websocket.xml](https://www.iana.org/assignments/websocket/websocket.xml)),
and you can talk WAMP with clients in C++/Java/C#/PHP/JS.

It's pretty nice for the IoT and real time apps.

------
reedcat
I have been using WAMP for a while now. It is a fairly established standard
for publish/subscribe/rpc with multiple implementations and examples.

