airflow.providers.apache.hive.transfers.hive_to_samba

This module contains an operator to move data from Hive to Samba.

Module Contents

Classes

HiveToSambaOperator

Execute hql code in a specific Hive database and load the results as a csv to a Samba location.

class airflow.providers.apache.hive.transfers.hive_to_samba.HiveToSambaOperator(*, hql, destination_filepath, samba_conn_id='samba_default', hiveserver2_conn_id='hiveserver2_default', **kwargs)[source]

Bases: airflow.models.BaseOperator

Execute hql code in a specific Hive database and load the results as a csv to a Samba location.

Parameters
  • hql (str) – the hql to be exported. (templated)

  • destination_filepath (str) – the file path to where the file will be pushed onto samba

  • samba_conn_id (str) – reference to the samba destination

  • hiveserver2_conn_id (str) – Reference to the :ref: Hive Server2 thrift service connection id <howto/connection:hiveserver2>.

template_fields: collections.abc.Sequence[str] = ('hql', 'destination_filepath')[source]
template_ext: collections.abc.Sequence[str] = ('.hql', '.sql')[source]
template_fields_renderers[source]
execute(context)[source]

Derive when creating an operator.

Context is the same dictionary used as when rendering jinja templates.

Refer to get_template_context for more context.

Was this entry helpful?