Skip to content
Art2link ESB HomeDocumentationBlogContact
Updated May 5, 2026
Patterns/Transformation/Content enricher

Content enricher

Fill in what the source left out. A message arrives with an id but not the details a destination needs; the enricher looks the rest up and merges it into the canonical message.

There are two clean ways to enrich, and the difference matters. For data that is static or derivable, a country name from a code, a check digit, a category from a table baked into the platform, use a lean custom function inside the map, including a single deliberate database lookup. For live data that must be fetched per record from a system of record, do the lookup on a port via a caller adapter.

thin message customerId only Enricher lookup & merge reference source enriched message + name, address, terms

Keeping live lookups on a port preserves everything the bus gives you: the call is visible, retryable and resilient, and a slow reference system does not freeze a map mid-transform.

In Art2link, compute the derivable case in the map with a custom function, but call it the right way. A function that derives a value from the message has to read its inputs from the current node, so invoke it from the XSLT with art:invoke and pass the loop-context nodes as arguments, art:invoke('lineTotal', Quantity, UnitPrice) inside the template that matches each line. Do not feed it binding tokens like {{Promoted.Order.Qty}}: bindings are resolved by a preprocessor before the map runs, so they are not loop-aware, every iteration receives the same single pre-resolved value, not the value of the line being processed. Reserve the binding form for genuinely scalar, message-level inputs. The live case, a current price, a credit status, takes the explicit shape: a two-way send port with a SQL Caller looks the value up and republishes the enriched message to the bus, where the rest of the flow picks it up.

Static vs live is the whole decision. Derivable from the data alone → custom function in the map. Needs a fresh read from another system → enrich on a port. Never hide a live call inside a map.