Chain transform

This topic tells you about the Application Accelerator Chain transform in Tanzu Application Platform (commonly known as TAP).

The Chain transform uses function composition to produce its final output.

Diagram of a chain transform.

Syntax reference

engine {
  T1()
  T2()
  T3()
}

Behavior of chain

A chain of T1 then T2 then T3 first applies transform T1. It then applies T2 to the output of T1, and finally applies T3 to the output of that. In other words, T3 to T2 to T1.

Dot notation

engine {
  T1().T2().T3()
}

Behavior of dot notation

A chain of T1 then T2 then T3 first applies transform T1. It then applies T2 to the output of T1, and finally applies T3 to the output of that. In other words, T3 to T2 to T1.

The dot notation is included to add the concept of operator priority. A good use for this concept is when a Merge is included in the chain of transforms.

For example:

engine {
  T1()
  + T2()
  + T3().T4()
}

In the example, the T3().T4() is resolved first before processing the declared merges as the transforms are using the dot notation.

check-circle-line exclamation-circle-line close-line
Scroll to top icon