Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Diagnostics for FlowDurabilityTest #960

Merged
merged 1 commit into from
Dec 2, 2024

Conversation

jglick
Copy link
Member

@jglick jglick commented Nov 25, 2024

Get occasional flakes in CI in FlowDurabilityTest.testPauseForcesLowDurabilityToPersist and some others (CloudBees-internal reference) that I do not understand:

org.junit.runners.model.TestTimedOutException: test timed out after 180 seconds
	at [email protected]/java.lang.Object.wait(Native Method)
	at app//org.jenkinsci.plugins.workflow.job.WorkflowRun$Owner.get(WorkflowRun.java:985)
	at app//org.jenkinsci.plugins.workflow.flow.FlowExecutionList.resume(FlowExecutionList.java:226)
	at app//org.jenkinsci.plugins.workflow.flow.FlowExecutionList$ItemListenerImpl.onLoaded(FlowExecutionList.java:217)
	at app//jenkins.model.Jenkins.<init>(Jenkins.java:1070)
	at …

After the restart, there are no warnings about the test build, and nothing in the log beyond

   0.612 [id=279]	INFO	jenkins.InitReactorRunner$1#onAttained: Completed initialization
 180.001 [id=1]	WARNING	o.j.hudson.test.JenkinsRule$2#evaluate: Test timed out (after 180 seconds).
 180.002 [id=263]	WARNING	o.j.p.w.job.WorkflowRun$Owner#get: failed to wait for durableAgainstClean #1 to be loaded
java.lang.InterruptedException
	at java.base/java.lang.Object.wait(Native Method)
	at org.jenkinsci.plugins.workflow.job.WorkflowRun$Owner.get(WorkflowRun.java:985)
	at …

and no other threads active. It is as if RunMap.retrieve calls reload (via <init>) but not onLoad? No real hypothesis at this point. The test cases in this class generally are clearly prone to flakiness (see the various sleep steps and Thread.sleep calls with no guard) but seem potentially important so I am reluctant to just disable them.

@jglick jglick requested a review from a team as a code owner November 25, 2024 15:14
@@ -87,6 +89,9 @@ public class FlowDurabilityTest {
@Rule
public TimedRepeatRule repeater = new TimedRepeatRule();

@Rule
public LoggerRule logging = new LoggerRule().record(WorkflowRun.class, Level.FINE);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jglick jglick merged commit 5198556 into jenkinsci:master Dec 2, 2024
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants