airflow.providers.apache.kylin.hooks.kylin

Module Contents

class airflow.providers.apache.kylin.hooks.kylin.KylinHook(kylin_conn_id: str = 'kylin_default', project: Optional[str] = None, dsn: Optional[str] = None)[source]

Bases: airflow.hooks.base.BaseHook

Interact with Kylin to run CubeSource commands and get job status.

Parameters
  • kylin_conn_id (str) -- The connection id as configured in Airflow administration.

  • project (Optional[str]) -- project name

  • dsn (Optional[str]) -- dsn

get_conn(self)[source]
cube_run(self, datasource_name, op, **op_args)[source]

Run CubeSource command which in CubeSource.support_invoke_command

Parameters
  • datasource_name --

  • op -- command

  • op_args -- command args

Returns

response

get_job_status(self, job_id)[source]

Get job status

Parameters

job_id -- kylin job id

Returns

job status

Was this entry helpful?