java.lang.NullPointerException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When deploying an artifact with a POM with no parent or version (see attached) Nexus fails with an "unexpected error" message in the UI and the following stack trace in the logs: {noformat} 2011-09-28 09:49:47 WARN [-1778998154-428] - o.s.n.r.a.ArtifactC~ - java.lang.NullPointerException at java.util.regex.Matcher.getTextLength(Matcher.java:1140) at java.util.regex.Matcher.reset(Matcher.java:291) at java.util.regex.Matcher.<init>(Matcher.java:211) at java.util.regex.Pattern.matcher(Pattern.java:888) at org.apache.maven.index.artifact.VersionUtils.isSnapshot(VersionUtils.java:55) at org.sonatype.nexus.rest.artifact.AbstractArtifactPlexusResource.getResourceStoreRequest(AbstractArtifactPlexusResource.java:110) at org.sonatype.nexus.rest.artifact.AbstractArtifactPlexusResource.upload(AbstractArtifactPlexusResource.java:413) at org.sonatype.plexus.rest.resource.RestletResource.upload(RestletResource.java:361) at org.sonatype.plexus.rest.resource.RestletResource.acceptRepresentation(RestletResource.java:257) at org.sonatype.nexus.rest.NexusRestletResource.acceptRepresentation(NexusRestletResource.java:77) at org.restlet.resource.Resource.post(Resource.java:688) at org.restlet.resource.Resource.handlePost(Resource.java:537) at org.restlet.Finder.handle(Finder.java:357) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) ... {noformat} We should put a guard in for this.
    via by Rich Seddon,
  • When deploying an artifact with a POM with no parent or version (see attached) Nexus fails with an "unexpected error" message in the UI and the following stack trace in the logs: {noformat} 2011-09-28 09:49:47 WARN [-1778998154-428] - o.s.n.r.a.ArtifactC~ - java.lang.NullPointerException at java.util.regex.Matcher.getTextLength(Matcher.java:1140) at java.util.regex.Matcher.reset(Matcher.java:291) at java.util.regex.Matcher.<init>(Matcher.java:211) at java.util.regex.Pattern.matcher(Pattern.java:888) at org.apache.maven.index.artifact.VersionUtils.isSnapshot(VersionUtils.java:55) at org.sonatype.nexus.rest.artifact.AbstractArtifactPlexusResource.getResourceStoreRequest(AbstractArtifactPlexusResource.java:110) at org.sonatype.nexus.rest.artifact.AbstractArtifactPlexusResource.upload(AbstractArtifactPlexusResource.java:413) at org.sonatype.plexus.rest.resource.RestletResource.upload(RestletResource.java:361) at org.sonatype.plexus.rest.resource.RestletResource.acceptRepresentation(RestletResource.java:257) at org.sonatype.nexus.rest.NexusRestletResource.acceptRepresentation(NexusRestletResource.java:77) at org.restlet.resource.Resource.post(Resource.java:688) at org.restlet.resource.Resource.handlePost(Resource.java:537) at org.restlet.Finder.handle(Finder.java:357) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) ... {noformat} We should put a guard in for this.
    via by Rich Seddon,
  • containsIgnoreCase throws NPE
    via GitHub by larsrc
    ,
  • NPE in Verifier
    via GitHub by njbartlett
    ,
    • java.lang.NullPointerException at java.util.regex.Matcher.getTextLength(Matcher.java:1140) at java.util.regex.Matcher.reset(Matcher.java:291) at java.util.regex.Matcher.<init>(Matcher.java:211) at java.util.regex.Pattern.matcher(Pattern.java:888) at org.apache.maven.index.artifact.VersionUtils.isSnapshot(VersionUtils.java:55) at org.sonatype.nexus.rest.artifact.AbstractArtifactPlexusResource.getResourceStoreRequest(AbstractArtifactPlexusResource.java:110) at org.sonatype.nexus.rest.artifact.AbstractArtifactPlexusResource.upload(AbstractArtifactPlexusResource.java:413) at org.sonatype.plexus.rest.resource.RestletResource.upload(RestletResource.java:361) at org.sonatype.plexus.rest.resource.RestletResource.acceptRepresentation(RestletResource.java:257) at org.sonatype.nexus.rest.NexusRestletResource.acceptRepresentation(NexusRestletResource.java:77) at org.restlet.resource.Resource.post(Resource.java:688) at org.restlet.resource.Resource.handlePost(Resource.java:537) at org.restlet.Finder.handle(Finder.java:357) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150)

    Users with the same issue

    odd
    2 times, last one,
    stigkj
    6 times, last one,
    Dunmer
    1 times, last one,
    Alireza Mohamadi
    1 times, last one,
    tyson925
    4 times, last one,
    24 more bugmates