cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

JOB API KEEPS SAYING THE JOB IS RUNNING

Anonymous
Not applicable

I have a library that waits until the job goes in the "TERMINATED" / "SKIPPED" state before continuing. It pools the JOB API.

Unfortunately, I'm experiencing cases where the job is terminated on the GUI but the API still keeps saying "RUNNING".

There is another option to wait until the job goes in not running the state?

1 ACCEPTED SOLUTION

Accepted Solutions

Anonymous
Not applicable

Sometimes it happens, sometimes it does not. The api is:

/api/2.1/jobs/runs/list

Assuming INTERNAL_ERROR as TERMINATED state seems to be the a good workaround.

This is my solution so far...

if life_cycle_state.upper() not in ("TERMINATED", "SKIPPED", "INTERNAL_ERROR"):

View solution in original post

3 REPLIES 3

jose_gonzalez
Databricks Employee
Databricks Employee

Hi @Alessio Palma​,

Do you have any logs that could help us to narrow down the root cause? Please share any logs you might have.

Prabakar
Databricks Employee
Databricks Employee

@Alessio Palma​ could you please provide the API that you are using? Also share some sample output and logs that would help us with some information.

Anonymous
Not applicable

Sometimes it happens, sometimes it does not. The api is:

/api/2.1/jobs/runs/list

Assuming INTERNAL_ERROR as TERMINATED state seems to be the a good workaround.

This is my solution so far...

if life_cycle_state.upper() not in ("TERMINATED", "SKIPPED", "INTERNAL_ERROR"):

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group