mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-16 05:22:22 +00:00
Trying to diagnose an NPE associated with cloudbees-template.
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)
This commit is contained in:
1 parent
abb64edf4d
commit
d9f3af5fef
2 files changed
+11
-3
No files matched your search
@@ -31,6 +31,7 @@ import org.apache.maven.model.Dependency;
|
||||
import org.apache.maven.model.ReportPlugin;
|
||||
|
||||
import java.io.Serializable;
|
||||
import javax.annotation.Nonnull;
|
||||
|
||||
/**
|
||||
* Version independent name of a Maven project. GroupID+artifactId.
|
||||
@@ -39,10 +40,16 @@ import java.io.Serializable;
|
||||
* @see ModuleDependency
|
||||
*/
|
||||
public class ModuleName implements Comparable<ModuleName>, Serializable {
|
||||
public final String groupId;
|
||||
public final String artifactId;
|
||||
public final @Nonnull String groupId;
|
||||
public final @Nonnull String artifactId;
|
||||
|
||||
public ModuleName(String groupId, String artifactId) {
|
||||
if (groupId == null) {
|
||||
throw new NullPointerException("Must specify groupId");
|
||||
}
|
||||
if (artifactId == null) {
|
||||
throw new NullPointerException("Must specify artifactId");
|
||||
}
|
||||
this.groupId = groupId;
|
||||
this.artifactId = artifactId;
|
||||
}
|
||||
|
||||
@@ -37,6 +37,7 @@ import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import java.util.ArrayList;
|
||||
import javax.annotation.Nonnull;
|
||||
|
||||
/**
|
||||
* Serializable representation of the key information obtained from Maven POM.
|
||||
@@ -51,7 +52,7 @@ final class PomInfo implements Serializable {
|
||||
|
||||
public static final String PACKAGING_TYPE_PLUGIN = "maven-plugin";
|
||||
|
||||
public final ModuleName name;
|
||||
public final @Nonnull ModuleName name;
|
||||
|
||||
/**
|
||||
* This is a human readable name of the POM. Not necessarily unique
|
||||
|
||||
Reference in new issue
Block a user