Bondy Connect
Skip to content

WAMP Compliance ​

Which parts of the WAMP specification Bondy Connect implements, and where it departs from it.

Each table has two status columns. Announced is what Bondy states in the roles of its WELCOME message, which is what a client library reads to decide which features to use. Implemented is what the router actually does. The two disagree in a few places; the notes say which.

Basic Profile ​

Transports and serialization ​

FeatureImplementedNotes
WebSocket transportYes
RawSocket transport (TCP and TLS)YesAlso over a Unix domain socket listener.
HTTP long-poll transportYesJSON only. See WAMP HTTP Transports.
HTTP Server-Sent Events transportYesJSON only. Bondy-specific; not part of the specification.
Batched WebSocket transportNoBondy accepts the batched subprotocols (wamp.2.json.batched and others) during the WebSocket handshake, but cannot decode their messages, so the session fails on the first message. Do not use them.
JSON serializationYesWebSocket subprotocol wamp.2.json; RawSocket serializer 1.
MessagePack serializationYesWebSocket subprotocol wamp.2.msgpack; RawSocket serializer 2.
CBOR serializationYesWebSocket subprotocol wamp.2.cbor; RawSocket serializer 3.
Erlang term serializationYesBondy-specific. WebSocket subprotocol wamp.2.erl; RawSocket serializer set by wamp.serializers.erl.
BERT serializationNoRefused on every transport, because its decoder can create atoms before the session authenticates.

See Serialization for how each serializer maps WAMP types.

Sessions and messages ​

FeatureImplementedNotes
One session per transport connectionYeswamp.connection_lifetime accepts only session.
Closing the session and connection on a protocol errorYesSee Protocol errors.
Validation of URIs and custom attribute keysYes
Agent identificationYes

Publish/Subscribe ​

FeatureImplementedNotes
Event ordering between a publisher and a subscriberPartialSee NC1.
One subscription, and one subscription ID, shared by every subscriber to a topicNoSee NC2.

Routed RPC ​

FeatureImplementedNotes
One registration, and one registration ID, shared by every callee of a procedureNoSee NC3.

Advanced Profile ​

Authentication ​

Authentication methodImplementedNotes
anonymousYesControlled by security.allow_anonymous_user.
ticketYesA ticket issued by Bondy. Supports Single Sign-on across realms.
wampcraYes
wamp-scramYes
cryptosignYes
cookieYesTransport-level, for the HTTP transports.
trustYesBondy-specific. Accepts an existing authid without credentials; restrict it with sources.
passwordYesBondy-specific. Sends the password in clear text; use it only over TLS.
oauth2YesBondy-specific.
tlsNoListed by Bondy, but has no implementation; a session that requests it is refused.

Publish/Subscribe ​

FeatureAnnouncedImplementedNotes
Subscriber black- and whitelistingYesYesBondy filters on exclude and eligible (session IDs), and on exclude_authid, exclude_authrole, eligible_authid and eligible_authrole, for every subscription match policy and for retained events. An empty eligible list delivers the event to no subscriber.
Publisher exclusionYesYesexclude_me defaults to true.
Publisher identificationYesYesdisclose_me defaults to true, so the publisher's session ID is disclosed unless it opts out.
Pattern-based subscriptionYesYes
Event retentionYesYesSee message retention.
Payload passthru modeYesYes
Session meta APIYesPartialSee Session meta API.
Subscription meta APIYesPartialBondy implements the wamp.subscription.* procedures and publishes the on_subscribe and on_unsubscribe events. Bondy does not publish on_create or on_delete; see NC4.
Topic reflectionYesYesThe wamp.reflection.topic.* procedures.
Publication trust levelsNoNo
Sharded subscriptionNoNo
Event historyNoNo
Subscription revocationNoNo

Routed RPC ​

FeatureAnnouncedImplementedNotes
Call timeoutYesYes
Call cancelingYesYesGranted only to a session that announces it. Bondy sends INTERRUPT only to a callee that announced call_canceling; for any other callee, kill and killnowait act as skip.
Caller identificationYesYesThe caller's session ID is disclosed unless both the callee's disclose_caller and the caller's disclose_me are false.
Pattern-based registrationYesYes
Shared registrationYesYesInvocation policies single, roundrobin, random, first and last. When sessions on one node register a procedure with single concurrently, exactly one registration succeeds.
Progressive call resultsYesYesGranted only to a session that announces it. Bondy asks a callee for progressive results only when the callee also announced call_canceling; any other callee settles the call with one final YIELD. See Dealer.
Progressive callsYesYesGranted only to a session that announces it. Bondy routes a progressive call only to a callee that announced both progressive_call_invocations and call_canceling.
Payload passthru modeYesYes
Registration meta APIYesPartialBondy publishes on_register and on_unregister, but not on_create or on_delete. See NC4.
Session meta APIYesPartialSee Session meta API.
Procedure reflectionYesYesThe wamp.reflection.procedure.* and wamp.reflection.error.* procedures.
Call trust levelsNoNo
Call rerouteNoNo
Sharded registrationNoNo
Registration revocationNoNo
Testament meta APINoNo

Session meta API ​

Bondy announces the session meta API on both the broker and dealer roles, and implements part of it:

  • wamp.session.get is implemented.
  • The wamp.session.on_join and wamp.session.on_leave events are published.
  • wamp.session.count, wamp.session.list, wamp.session.kill, wamp.session.kill_all, wamp.session.kill_by_authid and wamp.session.kill_by_authrole are not implemented, and fail with wamp.error.no_such_procedure.

Protocol errors ​

The table lists how the router replies to a message that it cannot accept. An ABORT closes the session and the connection.

MessageReply
A frame that does not decode: invalid JSON, malformed CBOR or MessagePack, a truncated frame, or bytes after the end of the messageABORT with reason wamp.error.protocol_violation
A frame whose payload (Arguments or ArgumentsKw) does not decode, or does not complete the messageABORT with reason wamp.error.protocol_violation
A frame that is not a WAMP array, or whose shape matches no WAMP messageABORT with reason wamp.error.protocol_violation
A request or session ID that is not an integer from 0 to 2^53ABORT with reason wamp.error.protocol_violation
A field of the wrong WAMP type, such as a Details or Options that is not a dictionary, or a URI that is not a stringABORT with reason wamp.error.protocol_violation
An option or detail with an invalid value, such as a HELLO with no rolesABORT with reason wamp.error.protocol_violation
Over the erl serialization, a term outside the WAMP data model, such as a tuple or an improper listABORT with reason wamp.error.protocol_violation
A URI that is not valid under wamp.uri.strictnessERROR with wamp.error.invalid_uri. The session stays open.

Bondy checks that the payload of every JSON and CBOR message decodes when the message arrives. A malformed payload therefore aborts the sender's session and never reaches a receiver.

Non-compliance cases ​

Bondy Connect is a distributed router built for continuous availability. Its nodes do not coordinate through consensus. The cases below are where the specification assumes a single router, or coordination between routers, that Bondy does not provide.

NC1 ​

Requirement — ordering of events. If a subscriber is subscribed to two topics and a publisher publishes one event to each, the subscriber receives them in publication order. A SUBSCRIBED reply reaches the subscriber before any EVENT for that subscription.

Behaviour. When the publisher and the subscriber are connected to the same node, Bondy delivers events in order. When they are connected to different nodes, Bondy does not guarantee the order.

NC2 ​

Requirement — shared subscriptions. A subscription is created when the first client subscribes to a topic, and every later subscriber to the same topic receives the same subscription ID.

Behaviour. Each subscriber gets its own subscription, with its own ID, even for the same topic. Sharing one subscription between subscribers on different nodes would require the nodes to agree on it, which needs coordination Bondy does not use.

NC3 ​

Requirement — shared registrations. A registration is created when the first callee registers a procedure, and every later callee of the same procedure receives the same registration ID.

Behaviour. Each callee gets its own registration, with its own ID, even for the same procedure. The reason is the same as for NC2.

NC4 ​

Requirement — creation and deletion meta events. The router publishes wamp.registration.on_create when a procedure gets its first registration, and wamp.registration.on_delete when it loses its last. The subscription meta API defines wamp.subscription.on_create and wamp.subscription.on_delete in the same way.

Behaviour. Bondy does not publish these four events. A cluster cannot decide which registration or subscription is the first or the last for a URI without coordinating its nodes. Each node would announce its own, and a subscriber would see a URI deleted while other nodes still serve it. Bondy publishes on_register, on_unregister, on_subscribe and on_unsubscribe for each registration and subscription instead. A client that needs to know whether a URI has registrations or subscriptions calls the wamp.registration.* or wamp.subscription.* meta procedures.