Skip to content

Messaging Model

FlowMQ's core messaging model is protocol-independent.

Producers publish messages with topics. A topic is the logical address of a message, and FlowMQ routes the message by matching the topic against destination filters. Consumers receive messages from these destinations, which can be streams, queues, or subscriptions.

The Basic Flow

  1. A producer publishes a message with a topic.
  2. FlowMQ uses the topic as the message's routing address.
  3. FlowMQ matches the topic against filters configured on streams, queues, and subscriptions.
  4. Each matching destination receives a copy of the message.
  5. Consumers read messages from those destinations.

Producers and consumers are decoupled from each other. A producer does not need to know which consumers exist. A consumer does not need to know which producer sent the message.

Messages

A message contains the application payload and optional headers. When a producer publishes the message, it is associated with a topic that FlowMQ uses as the routing address.

See Messages for more detail.

Topics

A topic is a logical address used for message routing.

Topics are hierarchical strings separated by /:

text
sensors/factory-1/temperature
orders/us/created
devices/vehicle-42/status

See Topics for more detail.

Topic Filters

A topic filter selects a set of topics.

Topic filters support wildcards:

WildcardMeaningExample
+Matches one topic levelsensors/+/temperature
#Matches zero or more levels at the endsensors/#

See Topics for more detail.

Destinations

Topics are routing addresses, not destinations. A destination is where matching messages are stored or delivered for consumers.

Destinations select messages by binding to topic filters. When a message topic matches a destination's filter, FlowMQ delivers a copy of the message to that destination.

Consumers receive messages from destinations. The destination type determines the consumption model:

DestinationPurposeConsumption model
StreamDurable event historyConsumers read by offset and can replay messages
QueueMessage queueMessages can accumulate in the queue until consumed; each message is delivered to one consumer
SubscriptionReal-time fan-outEach matching message is pushed to all active consumers

Bindings

A binding connects a destination to one or more topic filters.

Streams, queues, and subscriptions receive messages through bindings. When a message topic matches any filter in a binding, FlowMQ delivers a copy of the message to that destination.

If a message matches bindings on multiple destinations, FlowMQ delivers a copy to each matching destination.

What This Model Enables

  • Producers and consumers are decoupled.
  • One message can feed multiple downstream destinations, and consumers can receive messages from the destinations they need without affecting each other.
  • Real-time delivery and durable storage can be configured independently.
  • Destination types can be extended over time as new delivery or storage models are needed.
  • Routing rules can change without changing producers.