How can we pause a task until a specified time and how to resume the same task before the timeout with some external triggers

I see. For event-driven workflows, check those resources:

It’s hard for me to help because you are still describing solutions, not the actual problem or use case. Could you describe it more from a business perspective? What is this task that may time out doing? And when should this event be triggered?

@gaurav_amoga could you perhaps show how would you approach it in plain Python?