Skip to content

'Submission_method: Job Cluster' should provide databricks job run information (job_id / run_id) #420

@jeffrey-harrison

Description

@jeffrey-harrison

Describe the feature

Currently, we can't get the run-id of a job submitted via 'job_cluster'. As a result, we can't set view permissions for job runs when submitted via a databricks service principle, nor can we link to relevant job logs.

Send run-id and other job run information back to the user when job runs are submitted.

run-id exists here:

run_id = self._submit_job(whole_file_path, cluster_spec)

Job run information exists in the same function:

result_state = json_run_output["metadata"]["state"]["result_state"]

Describe alternatives you've considered

Currently, we query for all job runs in the past 24 hours and set permissions. This results in an excessive number of API calls to databricks.

Additional context

Job runs are not viewable after submission. We could fix this with an API call if we had the run-id.
Screenshot 2023-08-17 at 11 09 26 AM

Who will this benefit?

This will benefit users who use dbt-databricks to submit python models.

Are you interested in contributing this feature?

I should be able to contribute, depending on the complexity of returning this information.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions