Skip to content

Workflow Operators

Operators are the actions that workflow tasks run, such as running a query, waiting for data to arrive, or sending an email. Each task in a workflow definition uses one operator. This page lists the operators available in Treasure Workflow and the common parameters that you can use with every operator.

Control Operators

OperatorDescription
callCalls another workflow
http_callCall workflow fetched by HTTP
requireDepends on another workflow
loopRepeat tasks
for_eachRepeat tasks for values
for_rangeRepeat tasks for a range
ifConditional execution
failMakes the workflow failed
echoShows a message
waitWait for a specific duration

Treasure Data Operators

OperatorDescription
tdTreasure Data queries
td_runTreasure Data saved queries
td_ddlTreasure Data operations
td_loadTreasure Data bulk loading
td_for_eachRepeat using Treasure Data queries
td_waitWaits for data arriving at Treasure Data table
td_wait_tableWaits for data arriving at Treasure Data table
td_table_exportTreasure Data table export to S3
td_result_exportTreasure Data result exporter

Network Operators

OperatorDescription
mailSending email
httpMaking HTTP requests

Database operators

OperatorDescription
databricksExecute SQL statements on Databricks
pgPostgreSQL operations
snowflakeExecute SQL statements on Snowflake

Amazon Web Services Operators

OperatorDescription
s3_waitWait for a file in Amazon S3
s3_copyCopy files in Amazon S3
s3_deleteDelete files in Amazon S3
s3_moveMove files in Amazon S3
redshiftRedshift operations
redshift_loadRedshift load operations
redshift_unloadRedshift unload operations

Google Cloud Platform Operators

OperatorDescription
gcs_waitWait for a file in Google Cloud Storage
bqRunning Google BigQuery queries
bq_ddlManaging Google BigQuery Datasets and Tables
bq_extractExporting Data from Google BigQuery
bq_loadImporting Data into Google BigQuery

Scripting Operators

OperatorDescription
pyPython scripts

Unsupported Digdag Operators

OperatorDescription
embulkEmbulk data transfer
emrRunning Amazon EMR jobs
shRunning shell scripts
rbRunning Ruby scripts
param_getGetting persistent data
param_setStoring persistent data

Common Parameters

Common parameters control how a task runs, such as how long it can take. You can use the following parameters with every operator.

  • _timeout: DURATION

    The maximum time the task can take. If the task does not finish within this time, it fails, and the operation it started, such as a running query, is canceled.

    Set a duration with a time unit, such as 30s, 10m, or 1h 30m.

    The time is measured from the first time the task starts running. If the task retries, the retries count toward the same limit.

    Some operators cannot cancel their operation after it starts. For these operators, the task may run longer than the specified timeout. In that case, a warning appears in the task log.

    Examples:

    +load_data:
      td>: load_data.sql
      _timeout: 1h