@Miles If I understood correctly, when signaled and the execution token is still active in B, C, D then B, C, D has to complete the flow and then the loop should be terminated only after the execution.
Then attach a non interrupting timer boundary event to trigger the parallel execution to set flag as cancel=true without interrupting the current flow. So the execution of B, C, D flow will be continued and when the execution arrives at the gateway the condition will be evaluated to true for
#cancel==true and it will exit the looping.
When you start the process instance set process variable value as false for looping.
In the script task just set it like below:
Without having script task, the process variable can be set in end event also by adding execution listener and using inline scripts like below: