Please consider the following problem, either helping me with a fix for the proposed (non-working) solution below or by suggesting another solution for the mentioned high-level goal.
Thanks!
Details:
High-level goal: A page has a workflow which
- Creates tasks for several users each e.g. 3rd of the month
- Informs these users about the assigned tasks
- Waits until all tasks are completed (this can take days) and informs me
- I approve the page, then the cycle starts again on the 3rd of the next month
Solution approach:
Have a workflow "Idle" -> "In progress" -> "Review", where
- Idle expires on the 3rd of next month ("duedate")
- In progress creates the mentioned tasks when entered, it transitions to Review when the tasks are completed ("completed=Review")
- In Review ("trigger:statechanged|state=Review") a mail is sent to me, I "submit" to go back to state Idle
Problem:
If I give Idle a relative duedate of P1M, I get an unwanted shift: The relative expiry date is reevaluated when it reenters state Idle. This is a problem since state In Progress can take several days. E.g. On 3rd September the tasks are created. They all are finished on 10th September, I review the page on 10th September. Entering Idle on that date schedules the expiry date of Idle to 10th October, but it should be 3rd October.
I already considered
https://wiki.comalatech.com/display/CWL/State+expiry+dates and especially "Shared due dates" where a due date is "transported" from one state to another via metadata. The Idle didn't honor the new duedate, although I could verify that the metadata is set correctly.