Search This Blog

24 April 2009

Hudson Maven Release Plug-in Plug-in + Hudson Google Code plugin

I was excited to be able to use the Hudson Google Code plugin for my project.



Unfortunately, when I tried to also use the Hudson Maven Release Plug-in Plug-in with it, it always failed to authenticate...


[INFO] Checking in modified POMs...
[INFO] Executing: /bin/sh -c cd /home/hudson/jobs/ambrosia-jdk6-standalone/workspace/. && svn --username hudson@eoti.org --password '*****' --non-interactive commit --file /var/tmp/maven-scm-2033681108.commit --targets /var/tmp/maven-scm-1162162468517704084-targets
[INFO] Working directory: /home/hudson/jobs/ambrosia-jdk6-standalone/workspace/.
[HUDSON] Archiving /home/hudson/jobs/ambrosia-jdk6-standalone/workspace/./pom.xml to /home/hudson/jobs/ambrosia-jdk6-standalone/modules/org.eoti$ambrosia/builds/2009-04-24_00-59-40/archive/org.eoti/ambrosia/2.2-SNAPSHOT/pom.xml
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Unable to commit files
Provider message:
The svn command failed.
Command output:
svn: Commit failed (details follow):
svn: MKACTIVITY of '/svn/!svn/act/0776c9b3-28c2-443e-a144-97770aaff2b2': authorization failed: Could not authenticate to server: rejected Basic challenge (http://ambrosia.googlecode.com)

[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.BuildFailureException: Unable to commit files
Provider message:
The svn command failed.
Command output:
svn: Commit failed (details follow):
svn: MKACTIVITY of '/svn/!svn/act/0776c9b3-28c2-443e-a144-97770aaff2b2': authorization failed: Could not authenticate to server: rejected Basic challenge (http://ambrosia.googlecode.com)

at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:699)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:553)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:523)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:371)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:268)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:181)
at org.apache.maven.lifecycle.LifecycleExecutorInterceptor.execute(LifecycleExecutorInterceptor.java:65)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at hudson.maven.agent.Main.launch(Main.java:158)
at hudson.maven.MavenBuilder.call(MavenBuilder.java:162)
at hudson.maven.MavenModuleSetBuild$Builder.call(MavenModuleSetBuild.java:578)
at hudson.maven.MavenModuleSetBuild$Builder.call(MavenModuleSetBuild.java:524)
at hudson.remoting.UserRequest.perform(UserRequest.java:97)
at hudson.remoting.UserRequest.perform(UserRequest.java:46)
at hudson.remoting.Request$2.run(Request.java:236)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.apache.maven.plugin.MojoFailureException: Unable to commit files
Provider message:
The svn command failed.
Command output:
svn: Commit failed (details follow):
svn: MKACTIVITY of '/svn/!svn/act/0776c9b3-28c2-443e-a144-97770aaff2b2': authorization failed: Could not authenticate to server: rejected Basic challenge (http://ambrosia.googlecode.com)

at org.apache.maven.plugins.release.PrepareReleaseMojo.execute(PrepareReleaseMojo.java:190)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:483)
at hudson.maven.agent.PluginManagerInterceptor.executeMojo(PluginManagerInterceptor.java:182)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:678)
... 28 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 40 seconds
[INFO] Finished at: Fri Apr 24 01:00:22 PDT 2009
[INFO] Final Memory: 17M/218M
[INFO] ------------------------------------------------------------------------
channel stopped
Finished: FAILURE


This was because it was using http instead of https to do the checkout...
The solution was to only partially use the Google Code plugin...


4 comments:

  1. Excellent post, got me out of the oven!

    I've fired a bug report to Hudson GoogleCode Plugin issue tracker:

    https://hudson.dev.java.net/issues/show_bug.cgi?id=4919

    ReplyDelete
  2. I guess there is no reason to use the http protocol instead of https? Anonymous users can still checkout files using https.

    ReplyDelete
  3. To be honest, every file hosted on Google Code is free and open source, so I do have a hard time seeing a purpose behind it.

    ReplyDelete