Skip to content

Follow a command through DASP ​

This counter starts at 0. The client asks it to add 3, loses the receipt, and retries. The value remains 3.

Use Next to follow each message, or Play to run the trace. Select a stage to inspect retries, recovery, or a command conflict.

ClientHost / counter1session.open2session.opened
Saved historyNo updates

Client → host. Select the session, actor, and profile.

Message JSON · dasp.v1.session.open
CloudEvents : what is this message format?

CloudEvents is an open, widely used standard for event messages. DASP uses its common envelope for event identity, source, type, and data. DASP adds the session and recovery rules.

Why DASP uses CloudEvents →
{
  "specversion": "1.0",
  "id": "trace-open",
  "source": "urn:example:client:one",
  "type": "dasp.v1.session.open",
  "datacontenttype": "application/json",
  "data": {
    "session_id": "session-counter",
    "actor_id": "counter-main",
    "profile": {
      "id": "urn:example:dasp:counter",
      "version": "1"
    }
  },
  "requestid": "request-open"
}

This is a recorded example, not a running host. counter.add belongs to the example profile. The saved history and message JSON come from the checked-in recovery trace.

Read the identifiers ​

FieldMeaning
session_idThe shared actor session
command_idOne command; keep it and its input for retries
requestidOne request attempt and its reply
source + idOne event; replay preserves both
sequenceA saved update's position in the session

A client saves its last applied sequence, called its cursor, with its application state. A receipt, progress message, or received page does not advance that cursor by itself.

Check the example locally ​

Use Node.js 22 or later:

sh
git clone https://github.com/DASP-Protocol/dasp.git
cd dasp
npm ci
npm run spec:check

The checker validates messages and recorded recovery checkpoints. It writes dist/conformance-report.json. It does not execute an actor or test a live disconnect.

Inspect the trace file and counter profile.

Connect your implementation ​

Your profile defines commands, data, and what completion means. Your host saves admission and outcomes, executes work, and serves recovery reads. Your binding defines transport, authentication, and message routing.

A disconnect does not cancel accepted work. If the host cannot establish execution effects during recovery, it records uncertain and prevents unsafe repeat execution. DASP does not guarantee exactly-once external effects.

Start with the client packages or host implementation steps. Use the message catalog for all operations, including state views, progress, and errors.