An embedded tremor script is created with a special syntax that deviates from the operator creation. For a full reference see the section on tremor-query embedded-scripts.
The tremor script runtime allows to modify events or their metadata. To learn more about Tremor Script please see the related section.
script operator allows to modify the events metadata (via
$), and the script local
state which persists across single events.
out(default output used with
error- channel for runtime errors
<anything else>used when
emit event => "<anything else>"
define script rt
define script add
emit + 1
create script add;
select event from in into add;
select event from add into out;