KBEC-00249 - Retreiving Transition History in a Workflow


How can I tell which states were called, and which transitions were taken. A view such as:

Start \-> State 2 (succeeded) \-> State 3 (succeeded) \-> State 4 (failed) \-> End



Use the findObjects API on logEntry, and the filter with containerName equal to your workflowName. Something like:

my $wkfName="workflow_222_201308090956";
# create filterList
my @filterList;
# get only log associated to my workflow
push (@filterList, {"propertyName" => "containerName",
                    "operator" => "equals",
                    "operand1" => "workflow_222_201308090956"});
push (@filterList, {"propertyName" => "containerType",
                    "operator" => "equals",
                    "operand1" => "workflow"});
my ($success, $xPath) = InvokeCommander("", "findObjects", "logEntry",
                                        {maxIds => 5000,
                                         filter => \\@filterList ,
                                         sort => [ {propertyName => "time",  order => "ascending"} \]});

It should return a number of objects like:

    Invoking the sub-job for state 'Test'
    project: Training_user
    The sub-job 'job_34687_201308090956' for state 'Test' has completed
    project: Training_user

Applies to

  • Product versions: All
  • OS versions: Supported platforms

Have more questions?


Please sign in to leave a comment.