olchas commented on issue #8803:
URL: https://github.com/apache/airflow/issues/8803#issuecomment-660234954


   @mik-laj I agree, for users it will definitely be better to be able to 
specify it at task level. 
   
   I was looking at implementation of [google.auth.impersonated_credentials 
module](https://google-auth.readthedocs.io/en/latest/reference/google.auth.impersonated_credentials.html)
 and there I found that you can actually specify a chain of service accounts 
leading to the final one, that is supposed to grant the access token used for 
request. So I think the new argument for operators and hooks should accept both 
a string with single service account as well as a list, in case of which the 
last one is used as `target_principal`, while the rest are used as `delegates`. 
I think keeping one argument for operators/hooks designated for impersonation 
should suffice. 


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to