Tracing tuples with trace points
You can trace the flow of tuples and punctuation through the ports of an operator.
The flow of tuples and punctuation through an operator's port can be traced with the tracepoint command:
t <operator-name> (i|o) <port-index> [max-tuples] [d] [log] [p <predicate>]
(sdb) t CountOneLine o 0
Set + 1 Tracepoint CountOneLine o 0 cached:0/25 traced:0 in 00 secs
(sdb)
This command establishes a trace point on the output port (o
)
identified with port index zero (0
) for operator CountOneLine.
The output from the command indicates that the trace point is set.
The plus sign indicates that the trace point is enabled, the number
one (1
) following the plus sign is the trace point
identifier. The output also indicates that the trace point currently
has 0 tuples in its cache of up to 25 tuples.
You can use an optional numeric parameter to set the cache size
for a trace point. The default cache size is 25
.
You can use the optional d
parameter to define
a trace point that is initially disabled. While a trace point is disabled,
it does not cache tuples as they arrive at the associated port.
You can use the optional log
parameter to start
logging all cached tuples to a file. The file is placed in the data
directory for the stand-alone application or running PE.
You can use the optional p
parameter to provide
an SPL expression that is used as a predicate to conditionally trace
specific tuples. For more information, see Conditional probe points.