sfc-gh-madkins commented on issue #24456: URL: https://github.com/apache/airflow/issues/24456#issuecomment-1163556456
I like how this looks. Is there a way we can make it easy to grab an Airflow Connection to instantiate a snowpark connection? On Wed, Jun 22, 2022 at 2:59 PM Tomek Urbaszek ***@***.***> wrote: > How about creating @snowpark_task decorator as we do for virtualenv and > docker? > > > https://github.com/apache/airflow/blob/c3c1f7ea2851377ba913075844a8dde9bfe6376e/airflow/providers/docker/decorators/docker.py#L135-L139 > > > https://github.com/apache/airflow/blob/c3c1f7ea2851377ba913075844a8dde9bfe6376e/airflow/decorators/python_virtualenv.py#L71-L75 > > Of course such operator would have to provide session: > > @snowpark_taskdef count_user(session: Session): # session is required parameter > session.sql(...) > > Personally I found this more friendly than instantiating hooks or using > operators. > > Apart from that should we consider implementing custom XCom backend based > on reading query results using query-id? This can be a really nice addition > to Snowpark + Airflow combo. > > — > Reply to this email directly, view it on GitHub > <https://github.com/apache/airflow/issues/24456#issuecomment-1163544527>, > or unsubscribe > <https://github.com/notifications/unsubscribe-auth/ATSRCUYIKI3FLVNGIKGNUPDVQNWBJANCNFSM5YZNCYZA> > . > You are receiving this because you were mentioned.Message ID: > ***@***.***> > -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
