Pipeline job - how can I get the duration of stage?

15 views
Skip to first unread message

Ayellet

unread,
Apr 11, 2018, 10:26:53 AM4/11/18
to Jenkins Developers
Hi,

In my plugin , I try to get the data of pipeline job and its stages.
I need to know the duration of the stage in specific run, so I implemented this class:

org.jenkinsci.plugins.workflow.flow.GraphListener

But I can't get the stage's duration from the FlowNode.
When I call to getDuration - I get a strange results, sometimes it is not the same as in the UI (stage view).

My code:
StageNodeExt stageNode = StageNodeExt.create(flowNode);
stageNode getDurationMillis();

any idea?

thanks!!
Reply all
Reply to author
Forward
0 new messages