Skip to main content

Node Call node

Decision

What it does​

The Node Call node runs another node of the same data pipeline once per iteration of the Loop container it sits in. For each call it can replace some of the target node's settings with values from the current item, such as a customer id. The target keeps the rest of its own configuration.

With the cache on, iterations that resolve to the same key reuse the first result instead of running the target again.

When to use​

  • A Loop container walks a list, and each item needs the same configured node run with a different value, such as an API call per customer.
  • Many items share the same value, so a cache saves repeated calls.
  • You want one configured node instead of a copy per item.

Where it can go​

A Node Call works only inside a Loop container body. The run preflight stops a run with a Node Call outside a container, because there is no item to read.

Inside the body it connects like other processing nodes, for example to a Filter, Transform, Log or Notification.

Configure​

Select the node and press Configure to open Configure Node Call.

Save and Done stay unavailable while a required setting is missing. Cancel discards the changes made since the dialog opened or was last saved. A message confirms each save.

Target node: any node in this pipeline except Start, Source, Loop (container), Sub-workflow, another Node Call, and the Node Call itself.

Per-iteration bindings: pairs of a target setting name and a value. They apply to this call only. Blank names are dropped. A value is read one of three ways:

ValueResult
Only a reference, such as {{item.id}}The value it finds, with its type. On an item { "id": 7 } this is the number 7.
Text around a reference, such as cust-{{item.id}}Text: cust-7.
No {{ }}, such as CONCAT('x-', col)An expression, as in a Transform. A bare word is a column name; a quoted word is text.

item is the container's item variable. A reference to a path the item does not have stops the run, and the error names the binding, the reference and the values that were available.

Per-run cache: Cache results within a run turns it on.

  • Cache key template: required when the cache is on, read the same three ways as a binding. Use something that changes per item, such as {{item.id}}. A key that is the same on every iteration returns the first result for every item.
  • Cache version: change it to ignore earlier cached results without changing the key.
  • Persist across runs: keeps results for later runs. TTL (hours) sets how long, 24 by default.

Without Persist across runs, cached results last for the run.

Ports​

PortDirectionKindNotes
inindataRows given to the target node as its input.
outoutdataWhat the target node returns.
erroroutcontrolReceives the input rows when the call fails, for example a missing, deleted or not allowed target.

The run log records each call as a cache hit, a cache miss or a direct call, with the row count.

Examples​

Enrich each customer through a configured node.

  1. Put the Node Call inside the Loop container
    Drag it into the container so it becomes part of the body.
  2. Choose the target node
    A Transform, Compute, Filter, Message, Log, Load or other processing node in this pipeline.
  3. Bind the per-iteration values
    Set customerId to {{item.customerId}}. Only the settings you name change for each call.
  4. Turn on the cache
    Key it on the same value, {{item.customerId}}. Many rows share a customer, so the target runs once per customer.

With 5,000 orders across 300 customers and the cache keyed on customerId, the target runs 300 times instead of 5,000.

Troubleshooting​

SymptomCauseWhat to do
The run will not startThe Node Call is outside a Loop container.Drag it into the container body.
An error names a binding and a referenceThe item has no value at that path.Check the path and the container's item variable name, item by default.
Every item returns the same rowsThe cache key is the same on every iteration.Key the cache on a value that changes per item.
An error says the target is not allowedThe target is a Source, Start, Loop (container), Sub-workflow or Node Call.Choose a processing node. To read a source per item, read it before the container and loop over its rows.
An error says the target cannot be foundThe target node was deleted.Choose a target again.
Results look out of datePersisted results have not expired.Change Cache version.