cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
cancel
Showing results for 
Search instead for 
Did you mean: 

Can job 'run_as' be assigned to users/principals who actually run it?

Long_Tran
New Contributor

Can job 'run_as' be assigned to users/principals who actually run it? instead of always a fixed creator/user/pricipal?

When a job is run, I would like to see in the job setting "run_as" the name of the actual user/principal who runs it.

Currently, "run_as" is set to a fixed user/principal. If someone else runs this job (either manually or using APIs), "run_as" is still showed as the fixed user/principal, and not the actual user/principal who runs it.

Am I missing something or this feature is actually not available?

1 REPLY 1

Wojciech_BUK
Contributor III

This is not avaliable in Workflow/Jobs.
Job should newer be run as person who is executing the job, especialy in Production.
The reason is that the output might be not the same, base on person who is running the job (e.g. diffrent Row Level Access). 
If you must use Workflows, you could give people "Manage" permission over job and let them change run as every time (but that is ugly solution).

What you are looking for is something diffrent:

- give person ability to run notebook / package using all-purpose cluster

- if you want to do it via job and job cluster - let people use  JOB API "/api/2.1/jobs/run-now" 
https://docs.databricks.com/api/azure/workspace/jobs/runnow

Welcome to Databricks Community: Lets learn, network and celebrate together

Join our fast-growing data practitioner and expert community of 80K+ members, ready to discover, help and collaborate together while making meaningful connections. 

Click here to register and join today! 

Engage in exciting technical discussions, join a group with your peers and meet our Featured Members.