Jean-Francois Arcand works for Ning.com. Previously he has worked for Sun Microsystems where he created Grizzly (NIO Framework) , Atmosphere and was a significant contributor to the GlassFish Application Server. Jean-Francois is a DZone MVB and is not an employee of DZone and has posted 23 posts at DZone. You can read more from them at their website. View Full User Profile

The Pain is Over For Java.net's Maven Artifacts!

02.26.2010
| 5322 views |
  • submit to reddit

Deploying Maven artifacts using the java.net repository is always a challenge and most of the time the result is unpredictable...the good news is Sonatype's is opening it's Nexus OSS instance for all of the java.net project!

All the projects I'm involved that needs to deploy on java.net maven repository are daily failling (many many times) with the not so nice exception:

 

[HUDSON] Archiving http://hudson.sfbay/job/Atmosphere/org.atmosphere.samples$atmosphere-simple-jersey/ws/target/atmosphere-simple-jersey-sources.jar to /files/hudson/server/jobs/Atmosphere/modules/org.atmosphere.samples$atmosphere-simple-jersey/builds/2010-02-24_18-18-14/archive/org.atmosphere.samples/atmosphere-simple-jersey/0.6-SNAPSHOT/atmosphere-simple-jersey-sources.jar
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error installing artifact's metadata: Error while deploying metadata: Connection failed: Unable to connect to https://svn.dev.java.net/svn/maven2-repository/trunk/repository/

svn: The specified baseline is not the latest baseline, so it may not be checked out.
svn: CHECKOUT of svn/maven2-repository/!svn/bln/2053093': 409 Conflict (https://svn.dev.java.net)
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 22 minutes 9 seconds
[INFO] Finished at: Wed Feb 24 18:40:27 PST 2010
[INFO] Final Memory: 78M/168M
[INFO] ------------------------------------------------------------------------
Waiting for Hudson to finish collecting data\

This happens for project like Grizzly, Atmosphere and Jersey, making the deployment of SNAPSHOT and official release quite complicated. Project like GlassFish started using their own repository to workaround that issue. When I was at Sun we worked on tricks like committing the artifact manually using SSH (wow!), or use scripts that try over an over until it succeed (wow!). With Grizzly, it took sometimes 3 DAYS to deploy the official release. So I guess we can say the java.net repositoty is a little broken :-).

Now will it get fixed when java.net/kenai merge? We have to see...but Kenai doesn't have a Maven repository so I suspect the same one will be used, hence all the pain! But there is a good news! Sonatype is opening it's Nexus OSS instance to all java.net project (actually not only java.net...any OSS projects). You can read the official announcement here....the java.net migration day is targetted March 5! If you use Maven and deploy on java.net, I think that's a good opportunity to save pain and improve your release cycle!

From http://weblogs.java.net/blog/jfarcand

Published at DZone with permission of Jean-Francois Arcand, author and DZone MVB.

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)

Tags: