airflow.providers.apache.druid.operators.druid

DruidOperator

允許直接向 Druid 提交任務。

模組內容

class airflow.providers.apache.druid.operators.druid.DruidOperator(*, json_index_file, druid_ingest_conn_id='druid_ingest_default', timeout=1, max_ingestion_time=None, ingestion_type=IngestionType.BATCH, verify_ssl=True, **kwargs)[source]

基類: airflow.models.BaseOperator

允許直接向 Druid 提交任務。

引數:
  • json_index_file (str) – Druid 索引規範的檔案路徑

  • druid_ingest_conn_id (str) – 接受索引作業的 Druid overlord 的連線 ID

  • timeout (int) – 輪詢 Druid 作業以獲取攝取作業狀態的間隔時間(秒)。必須大於或等於 1

  • max_ingestion_time (int | None) – 假定作業失敗前的最大攝取時間

  • ingestion_type (airflow.providers.apache.druid.hooks.druid.IngestionType) – 作業的攝取型別。可以是 IngestionType.Batch 或 IngestionType.MSQ

  • verify_ssl (bool) – 是否使用 SSL 加密提交索引作業。如果設定為 False,則檢查連線資訊以查詢要使用的 CA 捆綁包路徑。預設為 True

template_fields: collections.abc.Sequence[str] = ('json_index_file',)[source]
template_ext: collections.abc.Sequence[str] = ('.json',)[source]
template_fields_renderers[source]
json_index_file[source]
conn_id = 'druid_ingest_default'[source]
timeout = 1[source]
max_ingestion_time = None[source]
ingestion_type[source]
verify_ssl = True[source]
execute(context)[source]

建立 operator 時派生。

Context 與渲染 jinja 模板時使用的字典相同。

請參考 get_template_context 獲取更多 context。

此條目是否有幫助?