Issue Type: Bug Bug
Assignee: Jesse Glick
Components: workflow-plugin
Created: 10/Nov/14 4:57 PM
Description:

https://jenkins.ci.cloudbees.com/job/plugins/job/workflow-plugin/org.jenkins-ci.plugins.workflow$workflow-aggregator/572/testReport/junit/org.jenkinsci.plugins.workflow.steps/TimeoutStepTest/basic/ showed repeated warnings:

... org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution check
FINE: could not check .../workspace/p
java.io.IOException: corrupted content in .../workspace/p/.a883d971/jenkins-result.txt: java.lang.NumberFormatException: For input string: ""
	at org.jenkinsci.plugins.durabletask.FileMonitoringTask$FileMonitoringController.exitStatus(FileMonitoringTask.java:136)
	at org.jenkinsci.plugins.durabletask.BourneShellScript$ShellController.exitStatus(BourneShellScript.java:123)
	at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.check(DurableTaskStep.java:188)
	at org.jenkinsci.plugins.workflow.steps.durable_task.DurableTaskStep$Execution.run(DurableTaskStep.java:151)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NumberFormatException: For input string: ""
	at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
	at java.lang.Integer.parseInt(Integer.java:504)
	at java.lang.Integer.parseInt(Integer.java:527)
	at org.jenkinsci.plugins.durabletask.FileMonitoringTask$FileMonitoringController.exitStatus(FileMonitoringTask.java:134)
	... 10 more

Unclear what caused jenkins-result.txt to be empty rather than contain a number, but at any rate there is a problem in DurableTaskStep that it continued to recheck the workspace every 15s and never gave up. FileMonitoringController could perhaps mark this exception as "fatal" rather than "transient", but that leaves it open to a race condition if the exit status is still being checked while written. So it is probably the responsibility of the caller (check) to give up and mark the step failed if exitStatus repeatedly throws an exception. (As distinct from getWorkspace repeatedly being null, which is normal enough if the slave stays offline for a while.)

Project: Jenkins
Labels: robustness
Priority: Minor Minor
Reporter: Jesse Glick
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to