Hello everyone,
I'm running into some difficulties regarding how TriggerTimer (and TriggerMultiple) is defined in XPDL 2.0 and 2.1. The spec says that TriggerTimer can be used to trigger an activity "Every Monday at 9AM, for example" but how to specify exactly that phrase doesn't appear to be defined.
For example, let's say I want to trigger an activity "every monday and wednesday at 8AM". As far as I can tell, this is not possible in XPDL 2.1. The information can be stuffed into the TimeDate expression or into ##other elements, but if this is done it is unlikely that an XPDL consumer will successfully read in any of the data.
The first problem with the TriggerTimer schema is that you can either use TimeDate, which triggers an event exactly once, or you can use TimeCycle, which doesn't allow you to specify the first one. For something like "Every Monday at 9AM", it seems that you need at least both. In fact, for XPDL 2.0 I managed to make it work by using both attributes. The XML is valid, but I realize that was not the intended use of those attributes.
The second problem is that TriggerMultiple doesn't allow two TriggerTimer elements - they all have to be different types. Removing that restriction would be helpful.
It my ideal world, it looks something like this:
| Code: |
<StartEvent>
<TriggerMultiple>
<TriggerTimer>
<TimeDate>2009-06-29T08:00</TimeDate>
<RepeatInterval>7d</RepeatInterval>
<RepeatCount>26</RepeatCount>
</TriggerTimer>
<TriggerTimer>
<TimeDate>2009-07-01T08:00</TimeDate>
<RepeatInterval>7d</RepeatInterval>
<RepeatCount>26</RepeatCount>
</TriggerTimer>
</TriggerMultiple>
</StartEvent>
|
A little more ambitious would be to reference triggers by name.
| Code: |
<Package>
<NamedTriggers>
<NamedTrigger Name="MonWed8AM">
<TriggerMultiple>
<!-- and so on -->
</TriggerMultiple>
</NamedTrigger>
</NamedTriggers>
</Package>
.
.
.
<StartEvent>
<Trigger>
<TriggerReference Name="MonWed8AM"/>
</Trigger>
</StartEvent>
|
So, that's my 2 cents. I'd love to hear some thoughts on this.
- Scott