Category : airflow-2.x

I am using airflow 2.0. I am trying to connect to redshift, using docker container on mac. Here is my from airflow import DAG from datetime import datetime,timedelta from airflow.operators.bash import BashOperator from airflow.operators.python import PythonOperator,BranchPythonOperator from airflow.providers.jdbc.hooks.jdbc import JdbcHook #Creating JDBC connection using Conn ID JdbcConn = JdbcHook(jdbc_conn_id=’Redshift_conn’) def getconnection(): JdbcConn.get_connection(‘Redshift’) print("connected") default_args ..

Read more