Skip to main content

Hi

I'm looking at ways to monitor FME Server using the REST API and would like to perhaps query for all failed jobs in the last n days/hours/minutes.

 

I can see it's possible with the V3 API to query for failed jobs - e.g.

 

https://myfmeserver/fmerest/v3/transformations/jobs/completed?completedState=failed

 

However, this will return all failed jobs. If we are monitoring for recent failures, we would want to query using dates or a timeframe. Is this currently possible?

 

Thanks

 

John

Hi @john_gis4bus​ ,

 

It is not currently possible to query this endpoint by date. This is a great suggestion, our team is currently working on Rest API V4 so I have passed this request on to our product owner. I'd also recommend you create an idea to request this support.

 

For now, you'd need to perform a filter on the result using the timeFinished attribute.

 


We've set up a daily schedule to migrate job history into a postgres table, a bit of duplication, however, when updating to a new version of FME Server it lets us keep all the history - Makes it easy to query the data with SQL. The FME Server database should also have this available to query directly.

If you wanted to do this web based via REST you could just create a workspace which queries the database and returns what you want between two given dates. Its a little more than a simple rest call, but it could be a way...


We've set up a daily schedule to migrate job history into a postgres table, a bit of duplication, however, when updating to a new version of FME Server it lets us keep all the history - Makes it easy to query the data with SQL. The FME Server database should also have this available to query directly.

If you wanted to do this web based via REST you could just create a workspace which queries the database and returns what you want between two given dates. Its a little more than a simple rest call, but it could be a way...

Thanks @virtualcitymatt​ for those workarounds. Quering the FME Server DB directly could be the way forward I think.


Hi @john_gis4bus​ ,

 

It is not currently possible to query this endpoint by date. This is a great suggestion, our team is currently working on Rest API V4 so I have passed this request on to our product owner. I'd also recommend you create an idea to request this support.

 

For now, you'd need to perform a filter on the result using the timeFinished attribute.

 

Thanks for confirming @hollyatsafe​ - I will certainly create an idea for this support.


Now raised as an idea at https://community.safe.com/s/idea/0874Q000000j0JKQAY/detail


Reply