Improving flexibility of workflow management systems