Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

Track Job duration

I want to track if any of my job is taking long time to run. How can i track this?

6 Community Answers

Matillion Agent  

Paul Johnson —

Hi Gaurav,
There are a couple of ways,

  1. You can take a look in your task history and see the run time
  2. Use the matillion api to get the current status of a job after a period of time.
  3. You can also export the time taken after a job completes to your data warehouse

Regards,
Paul


Gaurav Katwal —

Hi Paul,

I want to get notified if my job is running for more than a threshold time(10-15 mins)
Does Snowflake host all this metadata which I can use?


Matillion Agent  

Paul Johnson —

Hi Gaurav,
There is no out of the box notifications for this. However you could build a job in matillion that will run on a schedule (say every 15 mins) that calls the matillion API to check the status and start time of a running task, perform a calculation to see if the elapsed time is greater than 15 mins and then send a notification out.

Regards,
Paul


Gaurav Katwal —

There are couple of things with Matillion API:
1. start_time and end_time are strings. These should be timestamps. Even if i change it to timestamp, it gives values like '1601-01-02 19:15:38.764', ''
2. enqueuedTime should ideally be the time taken for a job to run. This has value like '1557388389431' In what unit is this?


Gaurav Katwal —

Also, It is not tracking the running jobs. It only shows jobs that have been completed.


Matillion Agent  

Paul Johnson —

Hi Guarav,
If you use the tasks API against a running job it should return the start time as shown in this example
The values are epoch numbers which you can use in a calculation

Regards,
Paul

Post Your Community Answer

To add an answer please login