Skip to content

Available now

Ordering and delivery ​

After acceptance ​

  • Accepted messages go to every consumer whose subscription matches the message_type: exact (story.context), a family (telling.*) or everything.
  • Order is kept per correlation_id: messages with the same correlation_id arrive in the order the bus published them. There is no order across different ids. Keep one correlation_id for a story's whole life (correlation_id.changed).
  • Delivery is at least once. A consumer can see the same message_id again after a failure, a replay or a redrive.
  • The message itself is never changed. A reader of the queue with AWS credentials receives the producer's exact bytes; the HTTPS pull API returns the same envelope, parsed, as JSON.

What a consumer receives Available now ​

Each consumer connection has its own queue, which you read over the HTTPS pull API or, with an AWS reader role you register, with AWS credentials.

  • Over the pull API, each message is the producer's envelope, parsed, with message_type, correlation_id, topic, producer_id, receive_count and enqueued_at alongside (Receive).
  • From the queue with AWS credentials, the body is the producer's envelope, byte for byte, and these SQS message attributes come with it: message_type, family, topic, correlation_id, producer_id, system_id, som_version.
  • A connection's filter chooses by message type, topic prefix and source (Subscriptions and filters).
  • Order is per correlation_id. While a message is received and not yet acknowledged, the rest of its story waits. A message you don't acknowledge comes back when its visibility runs out (60 seconds by default), and blocks the rest of its story for you until it succeeds or moves to the dead-letter queue, after 5 attempts unless you chose another limit for the connection.
  • Messages wait 14 days in the queue.

What a consumer must do ​

  • Ignore message_types and extensions you don't recognise. Don't branch on som_version.
  • Be idempotent on message_id: replay and redrive deliver again.
  • Keep the highest sequence_number per story_id and drop older snapshots. A message redriven from the dead-letter queue lands behind newer ones.

Replay Available now ​

The bus archives every accepted message (30 days on the Sandbox, 7 on Preview). From the portal you can have a time range delivered again to one of your queues, and move your dead-letter queue back to your queue. See Dead-letter queues and replay.

SOM is an open standard maintained by the SOM working group. This service is not endorsed by it.