예제 #1
0
    def __init__(  # type: ignore[no-untyped-def]
        self,
        *,
        datahub_conn_id: str,
        **kwargs,
    ):
        super().__init__(**kwargs)

        self.datahub_conn_id = datahub_conn_id
        self.generic_hook = DatahubGenericHook(datahub_conn_id)
예제 #2
0
    def __init__(
        self,
        *,
        datahub_conn_id: str,
        **kwargs,
    ):
        super().__init__(**kwargs)

        self.datahub_conn_id = datahub_conn_id
        self.generic_hook = DatahubGenericHook(datahub_conn_id)
예제 #3
0
def make_emitter_hook():
    # This is necessary to avoid issues with circular imports.
    from datahub.integrations.airflow.hooks import DatahubGenericHook

    _datahub_conn_id = conf.get("lineage", "datahub_conn_id")
    return DatahubGenericHook(_datahub_conn_id)