Discover the winners & finalists of the 2022 Dataiku Frontrunner Awards!READ THEIR USE CASES

Call back when abort job

Solved!
Romain_L
Level 3
Call back when abort job

Hello,
I have a question about the manual shutdown of jobs in DSS.
I am using a python recipe that calls an external service to DSS in http on another server.
I use a classic HTTP method, the problem is that if I kill the job manually, it kills the process without stopping the call.I would like that before killing the process I can send a last http request to stop the external service.
I don't know if I've made myself clear.
Thanks in advance for your answers 🙂
Have a nice day


Operating system used: Linux

0 Kudos
1 Solution
HarizoR
Developer Advocate

Hi Romain,

Unfortunately it is not possible to embed additional logic when manually aborting a recipe. A possible workaround would be to create a macro that would execute your termination logic before aborting the recipe.

Using the DSS job API, you should be able to retrieve the recipe's job and abort it properly.

 

Hope this helps!

 

Best,

Harizo

 

View solution in original post

2 Replies
HarizoR
Developer Advocate

Hi Romain,

Unfortunately it is not possible to embed additional logic when manually aborting a recipe. A possible workaround would be to create a macro that would execute your termination logic before aborting the recipe.

Using the DSS job API, you should be able to retrieve the recipe's job and abort it properly.

 

Hope this helps!

 

Best,

Harizo

 

Romain_L
Level 3
Author

Thank you very much for your answer and your suggestions !

Best,

Romain

0 Kudos