Skip to main content
Version: 0.3.0

The two projections

One contract, carried in two shapes of exchange. The operator projection is a call and an answer; the shell projection is a connection held open.

What differs​

The operator projectionThe shell projection
Addressoperator.sockshell.sock
The exchangeone operation, one answer; or one operation whose answer is a streamone connection carrying many calls, and the events that arrive while it is open
What accumulatesnothing between callsthe established actor, the subscriptions taken, the correlation of calls in flight
A subscription isan operation whose answer is a streamthe default: one stands from the moment the connection opens
It ends whenthe answer arrives, or the caller closes the streamthe transport closes, or the Core stops
  • Nothing about a held connection is persisted. A Core that restarts ends every connection it had. There is no reconnection token and no resumption of a call in flight; a client that returns opens a new connection, receives a new identity, and its standing subscription begins with a fresh snapshot.

What does not differ​

DiffersDoes not differ
the shape of the exchange: one answer, a stream, or a connectionwhich operations exist
whether a subscription is standing or takenwhat a subscription promises
how a refusal travels: a transport status, or a framethe code, the message and the detail in it
who may reach the addresswhat a caller who reached it may do
  • The same operations, with the same limits, on both. There is one operation union, and each projection is a way of carrying it: an operation is a member of the union, never of a service, so an operation cannot exist on one projection and not the other.
  • A held connection adds no operation. What it carries beyond a call is connection state: an identity established once, the subscriptions taken, and the correlation of what is in flight.

On a held connection​

Three things arrive on one connection, told apart mechanically:

Carried by
a call's answerthe call identity the caller chose, echoed on every frame of that call
an eventthe call identity of the subscription that selected it — the standing one unless the caller took another
the end of a callan explicit completion frame carrying that call identity
  • The call identity is the caller's, never the Core's. A caller can match an answer without having recorded anything the Core told it.
  • Every call completes explicitly. A call answered by one message completes with it; a call whose answer is a stream completes when the caller ends it or the Core does, and the completion says which. Silence always means not yet.
  • Cancelling a call in flight names its call identity and belongs to the connection that issued it. On the operator projection the same act is closing the stream.

Which projection a client speaks to​

It is decided by who remains on the other end, not by who typed.

The clientSpeaks to
a person typing a command that runs, prints and exitsthe operator projection
a person who asks to be connected to a deployment and staysthe shell projection
a script, a supervisor, a panel's back endthe operator projection

The manager's commands against a running instance are single acts, so the manager is an operator-projection client whoever invoked it.