This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 182139 - build fails with platform applications when using snapshot artifacts
Summary: build fails with platform applications when using snapshot artifacts
Status: RESOLVED FIXED
Alias: None
Product: www
Classification: Unclassified
Component: Builds & Repositories (show other bugs)
Version: 6.x
Hardware: PC Mac OS X
: P1 normal (vote)
Assignee: rnovak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-16 16:30 UTC by Kenneth Ganfield
Modified: 2010-04-14 14:34 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kenneth Ganfield 2010-03-16 16:30:48 UTC
When I create a Maven NetBeans Application and try to build the project, the build fails. By default the pom project for the application specifies "SNAPSHOT" as the artifact version.

The build output results show failure to find artifacts, eg:

Downloading: http://bits.netbeans.org/netbeans/trunk/maven-snapshot/org/netbeans/api/org-openide-text/SNAPSHOT/org-openide-text-20100316.063114-1.nbm
Downloading: http://bits.netbeans.org/netbeans/trunk/maven-snapshot/org/netbeans/api/org-openide-windows/SNAPSHOT/org-openide-windows-20100316.063114-1.nbm
------------------------------------------------------------------------
[ERROR]BUILD ERROR
------------------------------------------------------------------------

[ ... ]

Failed to resolve artifact.

47 required artifacts are missing.

for artifact: 
  com.mycompany:application:nbm-application:1.0-SNAPSHOT

from the specified remote repositories:
  central (http://repo1.maven.org/maven2),
  apache.snapshot (https://repository.apache.org/content/repositories/snapshots),
  netbeans.snapshot (http://bits.netbeans.org/netbeans/trunk/maven-snapshot),
  codehaus.snapshot (http://snapshots.repository.codehaus.org),
  netbeans (http://bits.netbeans.org/maven2),
  plexus-snapshot (http://oss.repository.sonatype.org/content/repositories/plexus-snapshots/)


If the version is changed from SNAPSHOT to RELEASE68, the project builds successfully
Comment 1 Geertjan Wielenga 2010-03-17 17:40:20 UTC
I get the same result. Using the dev build Java SE netbeans-dev-201003160201 on Ubuntu.
Comment 2 Geertjan Wielenga 2010-03-18 08:51:30 UTC
This issue blocks all work on the NetBeans Platform for Maven builds. Hence it is a P1, since NetBeans Platform is P1 for 6.9. To reproduce the problem, get a recent dev build, create a new NetBeans Platform application from Maven archetype, and build it. The stack trace shown below is the result of the build process, which fails.
Comment 3 Milos Kleint 2010-03-19 07:36:59 UTC
I suppose we've tracked it yesterday to the missing nbm files in the remote repository. reassigning to robert.
Comment 4 rnovak 2010-03-26 11:53:31 UTC
Maven snapshot repository should be now correct. Could you, please test it ?
It was for longer time affected by the broken NBMs build step in the production build. I did some fixes to prevent creation of incomplete maven snapshot repository.
Comment 5 Kenneth Ganfield 2010-03-26 13:48:00 UTC
seems to work
Comment 6 Kenneth Ganfield 2010-03-26 14:27:10 UTC
but it takes several minutes to build and then another several minutes to run as the IDE tries to download artifacts each time i build or run.

Eg:
Unable to find resource 'org.netbeans.api:org-openide-text:jar:SNAPSHOT' in repository netbeans (http://bits.netbeans.org/maven2)
Downloading: http://bits.netbeans.org/netbeans/trunk/maven-snapshot/org/netbeans/api/org-openide-text/SNAPSHOT/org-openide-text-SNAPSHOT.jar
Unable to find resource 'org.netbeans.api:org-openide-text:jar:SNAPSHOT' in repository netbeans.snapshot (http://bits.netbeans.org/netbeans/trunk/maven-snapshot)
Downloading: http://oss.repository.sonatype.org/content/repositories/plexus-snapshots//org/netbeans/api/org-openide-text/SNAPSHOT/org-openide-text-SNAPSHOT.jar
Unable to find resource 'org.netbeans.api:org-openide-text:jar:SNAPSHOT' in repository plexus-snapshot (http://oss.repository.sonatype.org/content/repositories/plexus-snapshots/)
Downloading: http://snapshots.repository.codehaus.org/org/netbeans/api/org-openide-text/SNAPSHOT/org-openide-text-SNAPSHOT.jar
Unable to find resource 'org.netbeans.api:org-openide-text:jar:SNAPSHOT' in repository codehaus.snapshot (http://snapshots.repository.codehaus.org)
Downloading: https://repository.apache.org/content/repositories/snapshots/org/netbeans/api/org-openide-text/SNAPSHOT/org-openide-text-SNAPSHOT.jar
Unable to find resource 'org.netbeans.api:org-openide-text:jar:SNAPSHOT' in repository apache.snapshot (https://repository.apache.org/content/repositories/snapshots)

Is this normal or specific to snapshots?
Comment 7 Antonin Nebuzelsky 2010-04-14 14:34:51 UTC
Closing as fixed.

In Beta builds snapshots are not used at all and it works very smoothly for me.

In trunk builds, repository of daily NBM snapshots is used, but after getting rid of maven plugin snapshot versions and with fixes of consistency of the daily NBM repo it works for me OK.