Observed in 1.509.2:
Parsing POMs
Failed to transfer Could not find artifact … in central (http://repo.maven.apache.org/maven2)
Archiving artifacts
ERROR: Processing failed due to a bug in the code. Please report this to jenkinsci-users@googlegroups.com
java.lang.NullPointerException
at hudson.tasks.ArtifactArchiver.perform(ArtifactArchiver.java:138)
at org.zeroturnaround.jenkins.LiveRebelDeployBuilder.getArtificatOrMetadata(LiveRebelDeployBuilder.java:194)
at org.zeroturnaround.jenkins.LiveRebelDeployBuilder.uploadConfiguration(LiveRebelDeployBuilder.java:171)
at org.zeroturnaround.jenkins.LiveRebelDeployBuilder.perform(LiveRebelDeployBuilder.java:108)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:812)
at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.build(MavenModuleSetBuild.java:828)
at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:779)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:594)
at hudson.model.Run.execute(Run.java:1575)
at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:485)
In 1.516:
java.lang.NullPointerException
at hudson.maven.ModuleName.equals(ModuleName.java:115)
at hudson.maven.MavenModuleSet.reconfigure(MavenModuleSet.java:1108)
at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.parsePoms(MavenModuleSetBuild.java:907)
at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:631)
The following code prints false.
public static void main(String[] args) {
Thread t = new Thread() {
@Override
public void run() {
System.out.println(Thread.currentThread().isInterrupted());
}
};
t.interrupt();
t.start();
}
1. Use AtomicFileWriter on the hypothesis that an exception during save() caused truncation.
2. Improve logging from the cleanup thread since that may be related to the root cause.
3. Regardless of the cause, recover more gracefully by deleting any truncated file rather than throwing the error up.
Jenkins with folders A job A/j
a top-level view to recurse into subfolders and include all available jobs and folders (so A and A/j)
=> builds for A/j are included twice, as view.builds iterate on its items, so get A/j + builds from A.