fluentscheduler / FluentScheduler

Automated job scheduler with fluent interface for the .NET platform.
Other
2.68k stars 410 forks source link

How to cancel a job automatically if it's not completed in a certain amount of time? #315

Open akshay-zz opened 2 years ago

akshay-zz commented 2 years ago

Is there's any way to cancel a job after certain amount of time it it's still executing. Also any oncancelled callback function/Event just to log the things.

tallesl commented 3 months ago

That's a nice suggestion.

It's always tricky to 'kill' things that are running, but maybe we can arrange something (maybe cancelling a cancellationtoken for the caller to manage).

There's a fancy name for "cancelling something if it's not completed in a certain amount of time" by the way: "timeout" ;)