airflow.contrib.sensors.cassandra_table_sensor

Module Contents

class airflow.contrib.sensors.cassandra_table_sensor.CassandraTableSensor(table, cassandra_conn_id, *args, **kwargs)[source]

Bases: airflow.sensors.base_sensor_operator.BaseSensorOperator

Checks for the existence of a table in a Cassandra cluster.

For example, if you want to wait for a table called ‘t’ to be created in a keyspace ‘k’, instantiate it as follows:

>>> cassandra_sensor = CassandraTableSensor(table="k.t",
...                                         cassandra_conn_id="cassandra_default",
...                                         task_id="cassandra_sensor")
template_fields = ['table'][source]
poke(self, context)[source]