Details
-
Type: Bug
-
Status: Open
-
Priority: Major
-
Resolution: Unresolved
-
Affects Version/s: 3.8
-
Fix Version/s: None
-
Component/s: Core
-
Labels:None
-
Number of attachments :
Description
Hi,
as I read the specification of a timeout, it is setting the controls to let a story time out, when a specified amount of time has passed. By the name this is a setting per story. So, when I have a timeout of 300s per story, I should be able to have 100 stories, which take 250 seconds each.
The way it is implemented is different, though. The StoryManager measures the start time right after it kicked off all stories, and is waiting for all of them to be completed.
public void waitUntilAllDoneOrFailed(BatchFailures failures) { long start = System.currentTimeMillis(); boolean allDone = false; while (!allDone) { allDone = true; for (RunningStory runningStory : runningStories.values()) { Future<ThrowableStory> future = runningStory.getFuture(); if (!future.isDone()) { allDone = false; long durationInSecs = storyDurationInSecs(start); long timeoutInSecs = embedderControls.storyTimeoutInSecs(); if (durationInSecs > timeoutInSecs) { Story story = runningStory.getStory(); StoryDuration storyDuration = new StoryDuration(durationInSecs, timeoutInSecs); embedderMonitor.storyTimeout(story, storyDuration); storyRunner.cancelStory(story, storyDuration); future.cancel(true); } break; }
Has this been resolved with
JBEHAVE-1037?