Can timer start event in subprocess work?

find two ref witch is different.

“Note: A subprocess cannot have a timer start event.”

The event types that can trigger both interrupting and non-interrupting event subprocesses are:

And when timeout, the timer in subproc was not start automaticlly, and interrrupte the main process:

diagram_1.bpmn (5.0 KB)

@thinkdoom It’s true that those pieces say different things, but that’s because they refer to different things. The first one:

Refers to embedded subprocesses (with a solid border) within a process. Since the activation of these is part of the regular control flow (connected to other flow nodes before and after), a timer start event doesn’t really make sense. The subprocess is simply started as soon as a token arrives to it. Nothing prevents you from delaying that actual start though; you could have an intermediate timer event immediately after the none start event, but that would simply cause a pause after the subprocess was started straight away.

The second quote:

Refers to event subprocesses, which activate an event subscription immediately once the scope they belong to is entered and wait for the occurrence of their start event. They are not connected to the rest of the flow they are positioned in and due to the event subscription it makes more sense to have other options for the start event, such as a timer.

In your model, using the timer start event this way is most likely correct for what you want to achieve, but it seems you are surprised that the timer interrupted the main flow. This is because the timer start event you modelled is of the interrupting kind. In Camunda Modeler, you will find there is an option to switch the type to a timer start event that is non-interrupting (use the little spanner). With that configuration, if the timer fires (which can happen while the main flow is in any state (in the current model)), an additional token will be created for the event subprocess, while the main flow srays exactly where it is.

hi, @tiesebarrell , thanks for your explanation, i’v understand what’s the diffrence.
another question is: can subprocess (embed) have " other xxx(such as message, condition, signal) event " be a start event?
there is no note in other events’ doc : “Note: A subprocess cannot have a xxx start event.”
or if a subprocess have a xxx start event(not blank start event), it must not be a embed subproc, but a event subproc.

and the model’s probelem is:
what i expect is it will interrrupte the main process.
but what happens is it didn’t interrrupte the main process.

@thinkdoom indeed, an embedded sub process can only have a none start event. This is because it is not started by an event, but by incoming sequence flow.

If configured correctly, the event sub process you have in that model should interrupt the main process. If it doesn’t, you have perhaps encountered a bug, but since it is rather standard functionality, that seems less likely. What exactly do you see that leads you to believe the main process is not cancelled? Keep in mind that if the event sub process is triggered, what is expected is that the process overall will keep running. However, there will be no more tokens in the main flow, but only in the event subprocess. Only after the event subprocess has also ended, the process instance as a whole will complete.