Appendix D: Pattern map, glossary and EIP Camel cross-reference

Every pattern of the book on one map by part, the terms the chapters use in a short glossary, and where Enterprise Integration Patterns with Camel covers the same pattern, by chapter and by event.

20 minutesAppendix DAppendices

The map holds 37 patterns, one or more from every chapter except 5, 6 and 10, which tune producers, consumers and connector offsets. Alongside them the chapters use a larger set of Kafka, Debezium, Kubernetes and Camel terms. A reader who holds a problem needs the pattern, a reader who meets a word needs its meaning, and a reader who knows Enterprise Integration Patterns with Camel (EIP Camel) needs to know which of its chapters goes with which of these. Three tables answer those questions.

The map

Seven columns, one per part, each listing the patterns of its chapters as boxes each with its chapter number
Figure D.1: Every pattern of the book, in the part that teaches it

The parts move outward from one service. Part 1 is the message and how it travels between two services. Part 2 makes publishing and consuming safe against a crash. Part 3 stores the history and reads it back in other shapes. Part 4 combines streams and coordinates services that share no transaction. Part 5 makes the flow visible. Part 6 runs the same services on Kubernetes.

Pick a pattern by the symptom:

Symptom Pattern Chapter
The consumer needs facts the event omits Event Notification, Event-carried state, Content Enricher 2, 3, 19
Events of one order arrive out of order Partitioned ordering, Resequencer 4
One slow job holds back the jobs behind it Competing Consumers on a share group 7
The row commits and the event is lost Transactional Outbox, Transaction Log Tailing 8, 9
The same event is applied twice Idempotent Consumer 11
A crash between write and offset commit Transactional Client 12
One record fails every time Dead Letter Channel 13
Load grows with the length of the history Snapshot, Projection from history 15, 17
A stored event has the wrong shape Upcaster, Compatible evolution 18
Two facts on two topics must meet Stream-stream join 20
A step failed after others committed Saga, Orchestrated saga 22, 23
Every service is healthy and orders wait Measure the flow 26
A batch has several steps and must survive a restart Step-wise batch with persisted step state (Process Manager) Appendix I
One input is too large for one worker Fan-out over partitions (Splitter) Appendix I
A total is right only when every part is in Aggregate on completion (Aggregator) Appendix I
A nightly batch overruns the cluster or starves other work Admission control with Kueue Appendix I
One part of a batch failed and the rest is done Replay failed steps only Appendix I

Glossary

Term Meaning Chapter
Acknowledgement The producer setting that says how many replicas must hold a record before the send succeeds; in a share group, the per-record answer from a worker 5, 7
Admission Kueue’s decision to reserve quota for a suspended Job’s Workload and let its pods start Appendix I
Aggregate One object, reached through its root, that owns every rule about one entity and rebuilds from its own events 14
Backlog Changes in the replication slot that the connector has not yet confirmed 26
Claim check A reference to a large payload kept in a store outside the message 3
ClusterQueue A Kueue resource that holds quota per resource flavor and admits Workloads in order Appendix I
Compaction Topic cleanup that keeps the newest record for each key 9, 19
Compensation A new event or command that undoes the business effect of an earlier committed step 22
Connector A Kafka Connect task that moves records between Kafka and another system 9, 10
Consumer group Consumers that share a topic’s partitions, one partition to one member 6
Dead letter A record the receiver cannot process, kept with its original bytes on a separate topic 13
Debezium The change data capture project that reads the PostgreSQL log 9
Event time The time stamped when the event happened, as opposed to the time it arrived 20, 21
Fencing Aborting the open transaction of an older producer instance that has the same transactional id 12
Field manager The name under which a client applies a resource; the API server records it as the owner of the fields it sets 30
Fold Applying events one after another to produce state 14, 15
Grace period How long a window stays open for late records after its end 21
Idempotent Applying it twice has the effect of applying it once 11
Inbox The table of applied event ids, written in the same transaction as the effect 11
Indexed Job A Kubernetes Job whose pods each get a completion index, retried and failed per index Appendix I
KRaft Kafka’s own controller quorum, which replaces ZooKeeper 28
Lag The distance between a group’s committed offset and the end of a partition 26
LocalQueue A namespaced Kueue resource that Jobs name in a label and that points to a ClusterQueue Appendix I
LRA Long Running Action: a saga held by a coordinator that calls each participant’s registered compensation 23
Node pool A set of Kafka nodes with one role, controller or broker, that Strimzi runs together 28
Offset A record’s position in a partition; a connector’s offset is its position in the database log 6, 10
Optimistic append Writing an event at the version that was loaded and failing if another writer got there first 14
Outbox A table whose rows are events, written in the same transaction as the state change 8
Partition One ordered log of a topic; the only unit in which Kafka orders records 4
Poison record A record that fails every time it is processed 13
Preemption Evicting an admitted Workload of lower priority to admit one of higher priority Appendix I
Process Manager A component that holds the state of a multi-step process and decides the next step Appendix I
Projection A read model built by folding the history and kept current by applying each new event once 16, 17
Read committed The consumer isolation level that hides records of open and aborted transactions 12
Reconcile An operator’s loop that moves the cluster toward the declared resource 28, 29
Record key The value that selects a record’s partition 4
Replica identity What PostgreSQL writes to the log about a row before an update or delete 9
Replication slot The database’s record of how far a log reader has confirmed 9, 10
ResourceFlavor A Kueue resource that names a kind of node capacity a ClusterQueue can hand out Appendix I
Share group Consumers that take any record and acknowledge it one at a time 7
Snapshot Aggregate state stored at one version; also a connector’s initial copy of a table 9, 15
Stream time The newest event time seen, which advances only when a record arrives 21
Tombstone A record with a key and no value that marks a deletion 9
Trace context The trace and span ids carried in a message so the next hop can continue or link the trace 25
Upcast Convert a stored event to the current shape when it is read 18
Watermark A bound on lateness: records older than it no longer join an open window Appendix C
Workload Kueue’s record of a Job’s resource request, admitted or waiting Appendix I

EIP Camel by pattern and event

EIP Camel teaches the patterns in Camel on one runtime; this book repeats those that Kafka changes and goes deeper on one stack. The relation is one word: same means EIP Camel covers the pattern as this book does, deeper means this book adds Kafka specifics, contrasts means the Kafka form and the Camel form differ in behaviour, and extends means the pattern goes past what EIP Camel covers.

Pattern Chapter EIP Camel chapter Relation
Event, Command, Document Message 1 7 Message Types same
Event Notification 2 7 Message Types deeper
Resequencer 4 11 Advanced Routing deeper
Competing Consumers 7 14 Consumer Patterns deeper
Publisher and subscriber tuning 5, 6 Appendix O: Kafka Producer Tuning, Appendix N: Kafka Consumer Tuning deeper
Share groups 7 Appendix P: Kafka Share Groups deeper
Transactional Outbox 8 15 Producer and Transactional Patterns deeper
Connector offsets 10 Appendix R: Managing Kafka Connect Offsets deeper
Idempotent Consumer 11 15 Producer and Transactional Patterns deeper
Transactional Client 12 15 Producer and Transactional Patterns deeper
Dead Letter Channel 13 5 Channel Reliability deeper
Content Enricher 19 12 Transformation Fundamentals contrasts
Join, Windowed aggregation 20, 21 13 Structural Transformation contrasts
Saga, Orchestrated saga 22, 23 10 Composed Routing extends
Quarkus Flow orchestration 23 Appendix G: Quarkus Flow deeper
Decisions with rules 24 Appendix F: Drools and Business Rules deeper
Trace context, metrics 25, 26 17 Observability extends
Correlation identifier 27 8 Message Metadata extends
Running on Kubernetes 28 to 35 Appendix T: Deploying Camel to Kubernetes extends
Process Manager, Splitter, Aggregator over batch steps Appendix I 10 Composed Routing extends

Event sourcing, CQRS and schema evolution (chapters 14 to 18) and the claim check have no chapter of their own in EIP Camel.

The same events appear in many chapters. The catalog below lists the chapters from 1 to 27 whose text or example names each event. Chapter 4 publishes its shipment events on edp.shipping.shipments; the topics below are the ones the other chapters use.

Event Topic Chapters
OrderPlaced edp.orders.placed 1, 2, 3, 5, 6, 7, 8, 11, 13, 14, 16, 17, 18, 22, 25, 26, 27
OrderCancelled edp.orders.cancelled 1, 3, 14, 16, 17, 18, 22, 23, 27
InventoryReserved edp.inventory.reserved 12, 15, 20, 22, 23, 27
InventoryInsufficient edp.inventory.insufficient 22, 23, 27
PaymentProcessed edp.payments.processed 6, 12, 14, 16, 20, 22, 23, 27
PaymentFailed edp.payments.failed 22, 23, 27
ShipmentScheduled edp.shipping.scheduled 4, 6, 14, 16, 19, 21
ShipmentInTransit edp.shipping.in-transit 4, 16
ShipmentDelivered edp.shipping.delivered 4, 16

References