Two user tasks (task A and B) are created in parallel, and when one task is completed need to cancel the other vice versa. This can be done with the use of a task listener (event on complete). However the issue is if both tasks are completed at the same time how to handle it?