One Store
The simplest example of persistence consists of one store with standard durables.
Store Backs a Transport
![](GUID-C7CE7986-C0F5-46A3-B7E7-F4383D2A20D8-display.jpg)
The diagram illustrates the simplest use case.
- In network A, program Pub1 publishes messages on endpoint EP1, while program Sub2 receives them on endpoint EP2.
We say that transport T1 is the direct path connecting the two endpoints.
- Store1 also receives the message stream from EP1, and retains each message until the subscriber object (S) in Sub2 acknowledges the message. If Sub2 were absent, or if the direct path failed, Store1 would retain unacknowledged messages, and retransmit them to Sub2 as needed.
We say that Store1 backs the network of endpoints: namely EP1 and EP2. This statement is equivalent to saying that Store1 backs all the direct paths in the network T1. We can also say that Store1 backs the message stream that flows from the publishing endpoint, EP1.
Notice these additional features of this example:
- Store1 operates alongside the transport T1: it parallels the direct path, but it does not replace T1.
- Messages from EP1 flow simultaneously along T1 and into Store1.
- A message does not flow from Store1 to EP2 unless Sub2 has missed that message, and later becomes present to accept it.
- Store1 maintains interest in the message stream even when Sub2 is absent.
- In the diagram Pub1 represents potentially many program processes, all of which publish on endpoint EP1. Their message streams merge into Store1, just as they merge in transport T1. Neither Store1 nor the subscribers in program Sub2 distinguish the origin of any message.
- Sub2 also represents potentially many program processes, each of which subscribes to a separate standard durable. Each durable ensures that its subscriber receives the entire merged message stream that Store1 captures.
Copyright © Cloud Software Group, Inc. All rights reserved.