Trigger Trigger

yaml
type: "io.kestra.plugin.cassandra.Trigger"

Wait for a query to return results on a Cassandra database.

Examples

Wait for a CQL query to return results, and then iterate through rows.

yaml
id: cassandra-trigger
namespace: io.kestra.tests
tasks:
  - id: each
    type: io.kestra.core.tasks.flows.EachSequential
    tasks:
      - id: return
        type: io.kestra.core.tasks.debugs.Return
        format: "{{ json(taskrun.value) }}"
    value: "{{ trigger.rows }}"

triggers:
  - id: watch
    type: io.kestra.plugin.cassandra.Trigger
    interval: "PT5M"
    session:
       endpoints:
          - hostname: localhost
       username: cassandra_user
       password: cassandra_passwd
    cql: "SELECT * FROM CQL_KEYSPACE.CQL_TABLE"
    fetch: true

Properties

cql

  • Type: string
  • Dynamic:
  • Required: ✔️

CQL query.

session

The session connection properties

conditions

  • Type: array
  • SubType: Condition
  • Dynamic:
  • Required:

List of conditions in order to limit the flow trigger.

fetch

  • Type: boolean
  • Dynamic:
  • Required:
  • Default: false

Whether to fetch the data from the query result to the task output.

fetchOne

  • Type: boolean
  • Dynamic:
  • Required:
  • Default: false

Whether to fetch only one data row from the query result to the task output.

interval

  • Type: string
  • Dynamic:
  • Required:
  • Default: 60.000000000
  • Format: duration

Interval between polling.

The interval between 2 different polls of schedule, this can avoid to overload the remote