Skip to end of metadata
Go to start of metadata

This document, together with the hello-world plugin, shows you how to get started with the plugin development.

Important!

Please first read the "before writing a plugin" page.

There are a lot of existing Jenkins plugins, and a lot of people with Jenkins plugin development experience that you can take advantage of!

Check whether there is an existing plugin you can already use, or contribute to, then get in touch via the jenkinsci-dev mailing list, or IRC and explain your plugin idea.
Either we can point you towards an existing plugin, useful APIs, or code snippets that would be helpful.

Table of Contents

What Can Plugins Do?

Jenkins defines extensibility points, which are interfaces or abstract classes that model an aspect of a build system. Those interfaces define contracts of what need to be implemented, and Jenkins allows plugins to contribute those implementations. See this document for more about extension points.

In this document, we'll be implementing a Builder that says hello. (built-in builders include Ant, Maven, and shell script. Builders build a project.)

Setting Up Environment

To develop a plugin, you need Maven 3 (why?) and JDK 6.0 or later. If this is the first time you are using Maven, make sure Maven can download stuff over the internet.

Nexus Users

If you are using the Nexus Maven Repository Manager, you can ignore these instructions, and instead, click here for instructions on how to add Jenkins build prerequisites and the proper settings.xml entries.

It may be helpful to add the following to your ~/.m2/settings.xml (Windows users will find them in %USERPROFILE%\.m2\settings.xml):

<settings>
  <pluginGroups>
    <pluginGroup>org.jenkins-ci.tools</pluginGroup>
  </pluginGroups>

  <profiles>
    <!-- Give access to Jenkins plugins -->
    <profile>
      <id>jenkins</id>
      <activation>
        <activeByDefault>true</activeByDefault> <!-- change this to false, if you don't like to have it on per default -->
      </activation>
      <repositories>
        <repository>
          <id>repo.jenkins-ci.org</id>
          <url>https://repo.jenkins-ci.org/public/</url>
        </repository>
      </repositories>
      <pluginRepositories>
        <pluginRepository>
          <id>repo.jenkins-ci.org</id>
          <url>https://repo.jenkins-ci.org/public/</url>
        </pluginRepository>
      </pluginRepositories>
    </profile>
  </profiles>
  <mirrors>
    <mirror>
      <id>repo.jenkins-ci.org</id>
      <url>https://repo.jenkins-ci.org/public/</url>
      <mirrorOf>m.g.o-public</mirrorOf>
    </mirror>
  </mirrors>
</settings>

This will let you use short names for Jenkins Maven plugins (i.e. hpi:create instead of org.jenkins-ci.tools:maven-hpi-plugin:1.61:create),
though this is unnecessary once you are already working in a plugin project (only useful for initial hpi:create).
Note that adding the Jenkins repositories in a profile like this is not really necessary since most (all?) plugins already define these repositories.
And the mirror declaration is probably unnecessary.

Creating a New Plugin

To start developing a new Jenkins plugin, use an IDE (below), or if you are more comfortable with Maven, run the following command:

$ mvn archetype:generate -Dfilter=io.jenkins.archetypes:empty-plugin

To create a plugin skeleton for Blue Ocean, please see the generator-blueocean-usain Yeoman generator.

This will ask you a few questions, like the groupId (the Maven jargon for the package name) and the artifactId (the Maven jargon for your project name), then create a skeleton plugin from which you can start with.

Make sure you can build this:

$ cd newly-created-directory
$ mvn package

Building a Plugin

To build a plugin, run mvn install. This will create the file ./target/pluginname.hpi that you can deploy to Jenkins.

$ mvn install

Setting up a productive environment with your IDE

NetBeans

NetBeans users can use the IDE's Maven support to open the project directly.

As you navigate through the code, you can tell NetBeans to attach source code JAR files by clicking the "Attach" button that appears in the top of the main content window. This allows you to read the Jenkins core source code as you develop plugins. (Or just select Download Sources on the Dependencies node.)

You are advised to use the NetBeans plugin for Jenkins/Stapler development. This offers many Jenkins-specific features. Most visibly, create a new plugin using New Project » Maven » Jenkins Plugin, and use Run roject to test it.

IntelliJ IDEA

IntelliJ 7.0 (or later) users can load pom.xml directly from IDE, and you should see all the source code of libraries and Jenkins core all the way to the bottom. Consider installing IntelliJ IDEA plugin for Stapler to make the development easier.

IntelliJ defaults to downloading sources and JavaDocs on demand. So, to see the source, you may need to click the Download artifacts button in the Maven Projects tab.

Eclipse

Use Eclipse Juno (4.2) or later for the best experience.

Eclipse versions between 4.5 and < 4.6.2 contain a bug that causes errors such as "Only a type can be imported. hudson.model.Job resolves to a package".
If you encounter this error please upgrade to Eclipse Neon.2 (4.6.2) or higher (Bug 495598).

As Jenkins plugins are Maven projects, Eclipse users have two ways to load a Jenkins plugin project. One is to use m2e, which tries to make Eclipse understand Maven "natively", and the other is to use Maven Eclipse plugin, which makes Maven generate Eclipse project definitions. At the moment, unless you have some prior experience with m2e, we currently recommend plugin developers to go with the Maven Eclipse plugin.

Eclipse users can run the following Maven command to generate Eclipse project files (the custom outputDirectory parameter is used to work around the lack of JSR-269 annotation processor support in Eclipse:)

$ mvn -DdownloadSources=true -DdownloadJavadocs=true -DoutputDirectory=target/eclipse-classes -Declipse.workspace=/path/to/workspace eclipse:eclipse eclipse:configure-workspace

Where /path/to/workspace is the path to your Eclipse workspace.

Once this command completes successfully, use "Import..." (under the File menu in Eclipse) and select "General" > "Existing Projects into Workspace".

Do not select "Existing Maven Projects", which takes you to the m2e route

See Jenkins plugin development with Eclipse for gotchas and other known Eclipse/Maven related issues with Jenkins plugin development.

See Eclipse alternative build setup for an alternative way of setting up the Eclipse build environment, that is a bit more technically involved than using maven, but can give faster build times.

Plugin Workspace Layout

The plugin workspace consists of the following major pieces:

pom.xml

Maven uses the pom.xml file to build your Jenkins plugin. All Jenkins plugins should be based on the Plugin Parent POM:

<parent>
    <groupId>org.jenkins-ci.plugins</groupId>
    <artifactId>plugin</artifactId>
    <version>2.2</version>
</parent>

If the project is created using the provided archetype, everything is already set up. Up to Jenkins 1.645 the Plugin Parent POM was part of the main Jenkins project and the POM version was the baseline Jenkins version to be used for the plugin.

When using Parent POM version 2.2 or later, the baseline version is selection using the jenkins.version property, e.g.:

<properties>
    <jenkins.version>1.609.1</jenkins.version>
</properties>

src/main/java

Java source files of the plugin.

src/main/resources

Jelly/Groovy views of the plugin. See this document for more about it.

src/main/webapp

Static resources of the plugin, such as images and HTML files.

Source Code

PluginImpl approach

(deprecated in favor of the Extension points approach below)

A plugin's main entry point may be a PluginImpl class that extends from Plugin. Once Jenkins detects this plugin class (via its inheritance relationship from Plugin), it will create an instance, and invoke methods.

Extension points approach

A Plugin class is optional; a plugin may simply implement extension points, registering them with the @hudson.Extension annotation for automatic detection by Jenkins.

The bulk work in the plugin consists in implementing those extension points. See the sample source code for more information about how a Builder is implemented and what it does.

Here are a few things about extension:

  • in general a plugin extension should extend an existing extension point (a class that implements ExtensionPoint), and define an inner static class extending the corresponding descriptor (a class extending hudson.model.Descriptor)
  • the @Extension annotation must be placed on the inner descriptor class to let Jenkins know about this extension
  • the descriptor handles the global configuration of the extension while the extension class itself handles the individual configuration of the extension. For instance in a plugin defining a class extending LabelAtomProperty, an object of this class is instantiated for each LabelAtom (provided that the plugin is activated by the user in the label's configuration page). If configuration parameters for each individual instance are required, they're handled via a config.jelly file stored in a resource package named after the extension class. When the configuration form is saved, Jenkins calls the extension constructor marked with the @org.kohsuke.stapler.DataBoundConstructor annotation, matching parameters by name

Debugging a Plugin

NetBeans 6.7+ users can just hit Debug. For all others, run the following command to launch Jenkins with your plugin:
Convenient:

mvnDebug hpi:run

Unix:

$ export MAVEN_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=8000,suspend=n"
$ mvn hpi:run

Windows:

> set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=8000,suspend=n
> mvn hpi:run

If you open http://localhost:8080/jenkins in your browser, you should see the Jenkins page running in Jetty. The MAVEN_OPTS portion launches this whole thing with the debugger port 8000, so you should be able to start a debug session to this port from your IDE.

Once this starts running, keep it running. Jetty will pick up all the changes automatically.

  1. When you make changes to view files in src/main/resources or resource files in src/main/webapp, just hit F5 in your browser to see the changes.
  2. When you change Java source files, compile them in your IDE (NetBeans 6.7+: Debug > Apply Code Changes) and Jetty should automatically redeploy Jenkins to pick up those changes. There is no need to run mvn at all.

    MAVEN_OPTS can be used to specify all sorts of other JVM parameters, like -Xmx

Changing port

If you need to launch the Jenkins on a different port than 8080, set the port through the system property jetty.port.

$ mvn hpi:run -Djetty.port=8090

Setting context path

maven-hpi-plugin 1.65 or later (used by parent POM 1.401 or later) can set the context path by using a system property. On more recent versions of Jenkins the "/jenkins" prefix is added automatically.

$ mvn hpi:run -Dhpi.prefix=/jenkins

Changing code while debugging

Depending on what you change, you can see it in the running instance without restarting the whole Maven process:

  • Views: Groovy/Jelly views are re-compiled every time a browser requests a page, so just reload a page in the browser and you'll see the changes. This is also true for help files you write.
  • Java code: If you are debugging, JVM's hot swap feature can be used to reload code so long as you do not touch the method signature. (For example, from NetBeans use Debug » Apply Code Changes.) Beyond that, you can hit ENTER in the Maven process and it'll reload the Jenkins webapp, though generally it is better to stop the process and start again. See Developing with JRebel for how to get a JRebel license for OSS projects to improve this experience.
  • POM: If you change POM, you'll have to stop and restart Maven to see the changes.

If you are using version 1.120 or later of maven-hpi-plugin, which would be the default when using version 2.16 or later of the plugin parent POM, you can use the same features to debug changes spanning multiple plugins, or even a custom build of Jenkins core. Just make sure you have SNAPSHOT dependencies set up between the associated Maven modules (<scope>test</scope> suffices), and that the upstream module(s) have been built (e.g., mvn -DskipTests clean install). Now hpi:run on the downstream plugin and you should be able to reload views defined in any of the linked modules.

Distributing a Plugin

To create a distribution image of your plugin, run the following Maven command:

$ mvn package

This should create target/*.hpi file. Other users can use Jenkins' web UI to upload this plugin to Jenkins (or place it in $JENKINS_HOME/plugins.)

Releasing a Plugin and Hosting a Plugin on jenkins-ci.org

If you got to this point, you should definitely consider hosting your plugin on jenkins-ci.org. Move on to this document for how to do that. This includes the instructions for releasing the plugin.

Using custom builds of plugins included in the Jenkins WAR

If you are building a patched version of one of the plugins in the Jenkins core, the deployment process is a bit different. This is because Jenkins will itself manage these plugins unless you tell it not to.

Deploying a custom build of a core plugin

  1. Stop Jenkins
  2. Copy the custom HPI file to $JENKINS_HOME/plugins
  3. Remove the previously expanded plugin directory
  4. Create an empty file called <plugin>.hpi.pinned - e.g. maven-plugin.hpi.pinned
  5. Start Jenkins

Other tips

  1. Consider running Maven like this mvn -o ... to avoid hitting repositories every time. This will make various operations considerably faster.
  2. Subscribe to the users' alias from here so that we can get in touch with you.
  3. When you bump up the version of Jenkins you depend on, make sure to run mvn clean once, in particular to delete target/work that Jetty uses. Newer versions may just use work, not target/work. Otherwise your Jetty may continue to pick up old left-over JAR files.
  4. If you have a high latency network connection to the Maven repository, you might find it faster to first run the build once on a server near to the maven repository, then rsync the .m2/repository folder across to your local computer
  5. The 'package' and 'install' targets will by default run many tests. You can add '-DskipTests' on the command-line to skip these (of course you should run the tests before committing any changes)
  6. The 'compiler:compile' goal is faster than 'compile', because it is a goal, rather than a lifecycle event, and therefore avoids certain earlier goals, such as setting up resources

Other resources

Besides this tutorial, there are other tutorials and examples available on line:

96 Comments

  1. Anonymous

    I think that the pom mentioned in this page is out of date. You will need to edit it to have the following:

     java.net
    url = http://download.java.net/maven/1

     java.net2
    url = http://download.java.net/maven/2

      1. Hi Kohsuke,

        I am trying to create a plugin for jenkins. I added metioned above xml to my settings.xml uder /.m2 and when I run mvn -cpu hpi:create I get the following error 

        settings.xml

        settings.xmlorg.apache.maven.plugins:maven-hpi-plugin' does not exist or no valid version could be found

        maven version that I have is 

        Apache Maven 2.2.1 (r801777; 2009-08-06 15:16:01-0400). 

        Can you please help. I have attached settings.xml which I modified.

        Thanks.

  2. We need to update the hpi plugin so that the httpPort bound during hpi:run is user configurable form the command line.

    E.g. something like

     mvn hpi:run -DhttpPort=xxxx

    As in some cases I already have a tomcat instance on 8080 that I'm not exactly keep to restart (as I'm doing hudson development while waiting for the tomcat instance to do some other stuff

      1. Hi,

        I have been getting the following errors while doing "mvn package" even though i have added proxy settings correctly.

        [INFO] Scanning for projects...
        Downloading: http://repo.jenkins-ci.org/public/org/jenkins-ci/plugins/plugin/1.410/plugin-1.410.pom
        Downloading: http://guice-maven.googlecode.com/svn/trunk/org/jenkins-ci/plugins/plugin/1.410/plugin-1.410.pom
        Downloading: http://repo.maven.apache.org/maven2/org/jenkins-ci/plugins/plugin/1.410/plugin-1.410.pom
        [ERROR] The build could not read 1 project -> [Help 1]
        [ERROR]
        [ERROR]   The project org.jenkins-ci.plugins:xunit:1.44-SNAPSHOT (C:\Sudhakar\MavenPlugins\jenkinsci-xunit-plugin-eca700
        2\pom.xml) has 1 error
        [ERROR]     Non-resolvable parent POM: Could not transfer artifact org.jenkins-ci.plugins:plugin:pom:1.410 from/to repo.
        jenkins-ci.org (http://repo.jenkins-ci.org/public/): Not authorized by proxy, ReasonPhrase:Proxy Authentication Required
         ( Forefront TMG requires authorization to fulfill the request. Access to the Web Proxy filter is denied.  ). and 'paren
        t.relativePath' points at wrong local POM @ line 4, column 13 -> [Help 2]
        [ERROR]
        [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
        [ERROR] Re-run Maven using the -X switch to enable full debug logging.
        [ERROR]
        [ERROR] For more information about the errors and possible solutions, please read the following articles:
        [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
        [ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException

        I am new to jenkins and maven. can any one help me out in this regard.

        Thanks in advance.

  3. Anonymous

    Hi -

    I followed the instructions and I got the following error when I tried 'mvn package' in the project the hpi archetype created:

    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Internal error in the plugin manager executing goal 'org.jvnet.hudson.tools:maven-hpi-plugin:1.11:apt-compi
    le': Unable to find the mojo 'org.jvnet.hudson.tools:maven-hpi-plugin:1.11:apt-compile' in the plugin 'org.jvnet.h
    udson.tools:maven-hpi-plugin'
    com/sun/mirror/apt/AnnotationProcessorFactory
    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 5 seconds
    [INFO] Finished at: Mon Aug 20 22:25:53 PDT 2007
    [INFO] Final Memory: 27M/64M
    [INFO] ------------------------------------------------------------------------

    1. Could you please file this as an issue in the issue tracker, and run the same with "mvn -X" and attach the log file?
      (You'd need to request the observer role in the project to do this — thanks!)

  4. Anonymous

    Hi,

    I followed your instructions (downloading Maven2, then getting the pom.xml and doing mvn package) but I can't modify the settings.xml... I don't have that file in my .m2 directory(sad)

    Could you help?

    Thanx

    1. Unknown User (franklafond)

      I was able to get past this point with the simple settings.xml file:

      <settings>
         <pluginGroups>
            <pluginGroup>org.jvnet.hudson.tools</pluginGroup>
         </pluginGroups>
      </settings>
      

       It worked for me.

      Frank LaFond. 

  5. I get the following error with the maven-hpi-plugin version 1.11:

    E:\coder\hgsls\java\skype>mvn org.jvnet.hudson.tools:maven-hpi-plugin:1.11:create
    [INFO] Scanning for projects...
    Downloading: http://repo1.maven.org/maven2/org/jvnet/hudson/tools/maven-hpi-plugin/1.11/maven-hpi-plugin-1.11.pom
    Downloading: http://repo1.maven.org/maven2/org/jvnet/hudson/tools/maven-hpi-plugin/1.11/maven-hpi-plugin-1.11.pom
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to resolve artifact.
    
    GroupId: org.jvnet.hudson.tools
    ArtifactId: maven-hpi-plugin
    Version: 1.11
    
    Reason: Unable to download the artifact from any repository
    
      org.jvnet.hudson.tools:maven-hpi-plugin:pom:1.11
    
    from the specified remote repositories:
      central (http://repo1.maven.org/maven2)
    

    But when i use maven-hpi-plugin version 1.14 it works. BTW it took 31 minutes 46 seconds.

  6. Anonymous

    Yo Kawaguchi... just have to say that Hudson's architecture (and your Stapler project) are just insanely elegant. High fives all around.

    1. Unknown User (michael.r.caron@gmail.com)

      Uh, yeah... I wasn't logged in. This is me.

  7. I got Maven 2.0.8 and installed it according to their directions, downloaded the pom.xml file into a new directory, and ran mvn package and got this error:

    [INFO] Scanning for projects...
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] The plugin 'org.jvnet.hudson.tools:maven-hpi-plugin' does not exist or no valid version could be found
    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: < 1 second
    [INFO] Finished at: Sat Feb 23 11:00:40 EST 2008
    [INFO] Final Memory: 1M/254M
    [INFO] ------------------------------------------------------------------------
    

    I also tried using a settings.xml file as described (the "crude" way) and got the same error.  I am not behind any proxy.

    Any ideas?  Since I am new to Maven I am pretty sure its some dumb thing I'm doing.... 

    1. I got the same problem that Matthew did with version 2.08 of maven.  I tried going back to 2.04 and that did not seem to help.

      Cheers!

      1. Oh never mind.  I looked in the ~/.m2/repository and found the version is 1.17 at this point.  Sorry!!

    2. Turns out I was right.  It was something dumb I was doing.  My firewall software was not allowing java.exe to access the internet.

  8. Anonymous

    I want to download the source for a plugin and make a patch.  But I can't even get the source!

    I'm behind a proxy that uses a username/password. I got Maven to download everything, but no source!

    And then I tried checking it out of CVS and got this:

    $ cvs "-d:pserver;proxy=proxyhost.com;proxyport=3128:guest@cvs.dev.java.net:/cvs" co hudson/hudson/plugin/co
    zsh: correct 'cvs' to '_cvs' [nyae]? n
    cvs checkout: WARNING: Ignoring method options found in CVSROOT: `proxy=proxyhost.com;proxyport=3128'.
    cvs checkout: Use CVS version 1.12.7 or later to handle method options.
    cvs checkout: warning: skipping invalid entry in password file at line 1
    cvs server: cannot find module `hudson/hudson/plugin/cobertura' - ignored
    cvs [checkout aborted]: cannot expand modules
    

    Any help?

    1. The error message says it all. There's no such module `hudson/hudson/plugin/cobertura'
      You made a typo. It's "plugins".

  9. Unknown User (cynic783)

     I followed the instructions and I get the following error when I do mvn hpi:run:[INFO] Started Jetty Server
    [INFO] Starting scanner at interval of 1 seconds.
    2008-03-04 13:15:12.765:/:INFO:  Stapler: init
    2008-03-04 13:15:12.781::WARN:  EXCEPTION
    javax.servlet.ServletException: there's no "app" attribute in the application context.
            at org.mortbay.jetty.servlet.ServletHolder.initServlet(ServletHolder.java:446)
            at org.mortbay.jetty.servlet.ServletHolder.getServlet(ServletHolder.java:370)
            at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:468)
            at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1074)
            at hudson.BasicAuthenticationFilter.doFilter(BasicAuthenticationFilter.java:79)
            at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1065)
            at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365)
            at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:185)
            at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
            at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:689)
            at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:391)
            at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:146)
            at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
            at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
            at org.mortbay.jetty.Server.handle(Server.java:285)
            at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:457)
            at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:751)
            at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:500)
            at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:209)
            at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:357)
            at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:329)
            at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:475)
    I am using Maven 2.0.8, Java 1.6.0_02 on Windows XP Pro SP2.  Am I doing something wrong?  I am new to Maven.

  10. Unknown User (erlingwl)

    I have problems with external dependencies:

    I get lots of these: Caused by: java.lang.NoClassDefFoundError: Could not initialize class com.sun.syndication.propono.atom.client.AtomClientFactory

    I have referenced the libraries using Maven 2, e.g.:

        <dependency>
          <groupId>propono</groupId>
          <artifactId>propono</artifactId>
          <version>0.6</version>
        </dependency> 

    The libraries are included in WEB-INF/lib

    I have also tried putting the libraries in tomcat/lib and also tomcat/webapps/hudson/WEB-INF/lib 

    Where should external jars be put? How should they be referenced?

    Thanks, Erling 


  11. Any help is appreciated...How do I resolve the error?

    C:\Program Files\Apache Software Foundation\apache-maven-2.0.8\tmp>mvn package
    [INFO] Scanning for projects...
    Downloading: http://download.java.net/maven/1//org.jvnet.hudson.tools/poms/tools\-1.4.pom
    Downloading: http://download.java.net/maven/2//org/jvnet/hudson/tools/tools/1.4/tools-1.4.pom
    Downloading: http://download.java.net/maven/2/org/jvnet/hudson/tools/tools/1.4/tools-1.4.pom
    Downloading: http://repo1.maven.org/maven2/org/jvnet/hudson/tools/tools/1.4/tools-1.4.pom
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Error building POM (may not be this project's POM).

    Project ID: null:maven-hpi-plugin:maven-plugin:1.18

    Reason: Cannot find parent: org.jvnet.hudson.tools:tools for project: null:maven
    -hpi-plugin:maven-plugin:1.18 for project null:maven-hpi-plugin:maven-plugin:1.1
    8

    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: < 1 second
    [INFO] Finished at: Sun Mar 23 23:00:15 PDT 2008
    [INFO] Final Memory: 1M/4M
    [INFO] ------------------------------------------------------------------------

    1. Unknown User (davidhayes)

      This is basically to do with the fact that the java.net maven source and the hudson source are slightly out of sync. Not to worry, a simple fix locally will fix this:

       Change the file:

      c:\documents and settings\your user\.m2\repository\org\jvnet\hudson\tools\maven-hpi-plugin\1.18\maven-hpi-plugin-1.18.pom
      (change this to whatever suits your operating system)

      Right near the top of the file, you'll see the following block:

        <parent>
          <groupId>org.jvnet.hudson.tools</groupId>
          <artifactId>tools</artifactId>
          <version>1.4</version>
          <relativePath>../pom.xml</relativePath>
        </parent>
      

       Change this to:

        <parent>
          <groupId>org.jvnet.hudson.tools</groupId>
          <artifactId>tools</artifactId>
          <version>1.1</version>
          <relativePath>../pom.xml</relativePath>
        </parent>
      


      Note the change of the version number. Now try again, and everything should work!

      1. You were 100% right.  Everything is working now.  -Thanks.

      2. Unknown User (maxsauer)

        Thanks for this, the tools-1.4.pom is not present inside repository. It would be fine to have a note in the tutorial above.

      3. This is fixed now. In the future, please report these issues to the issue tracker, so that we can fix it, instead of asking everyone to work around the problem.

  12. Unknown User (gworas@gmail.com)

    Can anybody send me pom.xml from https://hudson.dev.java.net/source/browse/*checkout*/hudson/hudson/tools/bootstrap/pom.xml
    Any time I try to access it I do see response about Unknown location: hudson/tools/bootstrap/pom.xml

    1. Link fixed. This was due to CVS->SVN migration.

  13. Unknown User (munish g)

    When i run mvn package command, I get this error:

    [INFO] [hpi:apt-compile]
    [INFO] Compiling 2 source files to /opt/setups/apache-maven-2.0.9/agitar/target/classes
    [FATAL ERROR] org.jvnet.hudson.maven.plugins.hpi.AptMojo#execute() caused a linkage error (java.lang.NoClassDefFoundError) and may be out-of-date. Check the realms:
    [FATAL ERROR] Plugin realm = app0.child-container[org.jvnet.hudson.tools:maven-hpi-plugin]
    urls[0] = file:/root/.m2/repository/org/jvnet/hudson/tools/maven-hpi-plugin/1.20/maven-hpi-plugin-1.20.jar
    urls[1] = file:/root/.m2/repository/org/apache/maven/maven-archiver/2.0.1/maven-archiver-2.0.1.jar
    urls[2] = file:/root/.m2/repository/org/codehaus/plexus/plexus-utils/1.0.4/plexus-utils-1.0.4.jar
    urls[3] = file:/root/.m2/repository/org/codehaus/plexus/plexus-archiver/1.0-alpha-4/plexus-archiver-1.0-alpha-4.jar
    urls[4] = file:/root/.m2/repository/org/mortbay/jetty/maven-jetty-plugin/6.1.1/maven-jetty-plugin-6.1.1.jar
    urls[5] = file:/root/.m2/repository/commons-el/commons-el/1.0/commons-el-1.0.jar
    urls[6] = file:/root/.m2/repository/org/mortbay/jetty/jetty/6.1.1/jetty-6.1.1.jar
    urls[7] = file:/root/.m2/repository/org/mortbay/jetty/jetty-util/6.1.1/jetty-util-6.1.1.jar
    urls[8] = file:/root/.m2/repository/org/mortbay/jetty/servlet-api-2.5/6.1.1/servlet-api-2.5-6.1.1.jar
    urls[9] = file:/root/.m2/repository/org/apache/maven/maven-plugin-tools-api/2.0/maven-plugin-tools-api-2.0.jar
    urls[10] = file:/root/.m2/repository/org/mortbay/jetty/jetty-plus/6.1.1/jetty-plus-6.1.1.jar

    ..............

    .........

    [FATAL ERROR] Container realm = plexus.core
    urls[0] = file:/opt/setups/apache-maven-2.0.9/lib/maven-2.0.9-uber.jar
    [INFO] ------------------------------------------------------------------------
    [ERROR] FATAL ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] com.sun.tools.apt.Main
    [INFO] ------------------------------------------------------------------------
    [INFO] Trace
    java.lang.NoClassDefFoundError: com.sun.tools.apt.Main
            at org.jvnet.hudson.maven.plugins.hpi.AptCompiler.compileInProcess(AptCompiler.java:62)
            at org.jvnet.hudson.maven.plugins.hpi.AptCompiler.compile(AptCompiler.java:50)
            at org.jvnet.hudson.maven.plugins.hpi.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:486)
            at org.jvnet.hudson.maven.plugins.hpi.CompilerMojo.execute(CompilerMojo.java:111)
            at org.jvnet.hudson.maven.plugins.hpi.AptMojo.execute(AptMojo.java:21)
            at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:451)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:499)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:478)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:291)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
            at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
            at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
            at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:615)
            at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
            at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
            at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
            at org.codehaus.classworlds.Launcher.main(Launcher.java:375)

    I am struck at this point. Can anyone help?

  14. Unknown User (pdxjjb)

    Munish, I take it from the appearance of codehaus in your stack backtrace that you may be using the "mevenide" plugin for netbeans.  If so, please look at the email archives for the last few days at http://www.nabble.com/codehaus---mevenide-f11958.html because there appears to be a problem with the latest version of the plugin.

  15. If you get an error like this:

    >mvn org.jvnet.hudson.tools:maven-hpi-plugin:1.20:create

    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to resolve artifact.

    Missing:
    ----------
    1) com.sun:tools:jar:1.5

    You probably haven't set JAVA_HOME correctly.

  16. $ mvn org.jvnet.hudson.tools:maven-hpi-plugin:1.20:create
    [INFO] Scanning for projects...
    Downloading: http://repo1.maven.org/maven2/org/jvnet/hudson/tools/maven-hpi-plug
    in/1.20/maven-hpi-plugin-1.20.jar
    [INFO] Cannot find mojo descriptor for: 'org.jvnet.hudson.tools:maven-hpi-plugin
    :1.20:create' - Treating as non-aggregator.
    [INFO] ------------------------------------------------------------------------
    [INFO] Building Maven Default Project
    [INFO]    task-segment: [org.jvnet.hudson.tools:maven-hpi-plugin:1.20:create]
    [INFO] ------------------------------------------------------------------------
    Downloading: http://repo1.maven.org/maven2/org/jvnet/hudson/tools/maven-hpi-plug
    in/1.20/maven-hpi-plugin-1.20.jar
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] A required plugin was not found: Plugin could not be found - check that t
    he goal name is correct: Unable to download the artifact from any repository
    


    I like Hudson, and would like to contribute a plugin. However, in spite of the fact that I've built and deployed more than 100 enterprise Java projects since 1999, Maven absolutely makes me sick. I cringe at all the wonderful projects that are adopting it.

    I followed all the directions above, and tried anything in the comments that looked like it would help. Please reconsider your choice of this miserable tool.

    1. Did you update your settings file as described in section "Setting Up Environment"?

      1. Yes I did. I was able to get it to create the sample project by downloading the failed plugin manually. Did I mention that Maven sucks?

        However, with the help of the sample project and the documentation, I see how easy it is to create my plugin using Ant.

        1. Hi Kenneth,

          The version should be 1.21 instead of 1.20. Then it should work fine.

  17. Unknown User (victorhg@gmail.com)

    Hello!While creating a project, i'm receiving the following error:

     $> mvn org.jvnet.hudson.tools:maven-hpi-plugin:1.23:create -e
    
    + Error stacktraces are turned on.
    [INFO] Scanning for projects...
    [INFO] ------------------------------------------------------------------------
    [INFO] Building Maven Default Project
    [INFO]    task-segment: [org.jvnet.hudson.tools:maven-hpi-plugin:1.23:create] (aggregator-style)
    [INFO] ------------------------------------------------------------------------
    [INFO] ------------------------------------------------------------------------
    [ERROR] FATAL ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Lorg/apache/maven/archetype/Archetype;
    org.apache.maven.archetype.Archetype
    [INFO] ------------------------------------------------------------------------
    [INFO] Trace
    java.lang.NoClassDefFoundError: Lorg/apache/maven/archetype/Archetype;
        at java.lang.Class.getDeclaredFields0(Native Method)
        at java.lang.Class.privateGetDeclaredFields(Class.java:2291)
        at java.lang.Class.getDeclaredField(Class.java:1880)
        at hidden.org.codehaus.plexus.util.ReflectionUtils.getFieldByNameIncludingSuperclasses(ReflectionUtils.java:31)
        at org.codehaus.plexus.component.composition.FieldComponentComposer.getFieldByName(FieldComponentComposer.java:212)
        at org.codehaus.plexus.component.composition.FieldComponentComposer.findMatchingField(FieldComponentComposer.java:171)
        at org.codehaus.plexus.component.composition.FieldComponentComposer.assembleComponent(FieldComponentComposer.java:62)
        at org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:68)
        at org.codehaus.plexus.DefaultPlexusContainer.composeComponent(DefaultPlexusContainer.java:1486)
        at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:29)
        at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:101)
        at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:105)
        at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:95)
        at org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:48)
        at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:331)
        at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:312)
        at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:440)
        at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:609)
        at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:429)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:512)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:482)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:227)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
        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 org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
    Caused by: java.lang.ClassNotFoundException: org.apache.maven.archetype.Archetype
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
        at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
        at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
        at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
        ... 36 more
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 9 seconds
    [INFO] Finished at: Tue Nov 18 20:41:43 BRST 2008
    [INFO] Final Memory: 8M/18M
    [INFO] ------------------------------------------------------------------------
     
    

    System: Ubuntu 8.10

    I didn't install maven as an ubuntu's package, but as a zip file... the following program works well (creating a simples web application):

    $> mvn archetype:create
    


    Any suggestions?

    Thanks a lot!

  18. Unknown User (tekolehm)

    Could you add the instructions on how to do it the "right" way (with pluginRepository) now that the Maven bug has been resolved?

  19. hpi:create isn't working for me. I'm using maven-hpi-plugin 1.34 with Maven 2.0.9.

    [blalor@vm-fc8 ...d_roots/hudson_deploy_plugin/checkout]> emacs_mvn_helper.sh -Phudson-plugin-dev  org.jvnet.hudson.tools:maven-hpi-plugin:1.34:create -e
    + Error stacktraces are turned on.
    [INFO] Scanning for projects...
    [INFO] ------------------------------------------------------------------------
    [INFO] Building Maven Default Project
    [INFO]    task-segment: [org.jvnet.hudson.tools:maven-hpi-plugin:1.34:create] (aggregator-style)
    [INFO] ------------------------------------------------------------------------
    [INFO] Setting property: classpath.resource.loader.class => 'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
    [INFO] Setting property: velocimacro.messages.on => 'false'.
    [INFO] Setting property: resource.loader => 'classpath'.
    [INFO] Setting property: resource.manager.logwhenfound => 'false'.
    [INFO] **************************************************************
    [INFO] Starting Jakarta Velocity v1.4
    [INFO] RuntimeInstance initializing.
    [INFO] Default Properties File: org/apache/velocity/runtime/defaults/velocity.properties
    [INFO] Default ResourceManager initializing. (class org.apache.velocity.runtime.resource.ResourceManagerImpl)
    [INFO] Resource Loader Instantiated: org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
    [INFO] ClasspathResourceLoader : initialization starting.
    [INFO] ClasspathResourceLoader : initialization complete.
    [INFO] ResourceCache : initialized. (class org.apache.velocity.runtime.resource.ResourceCacheImpl)
    [INFO] Default ResourceManager initialization complete.
    [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Literal
    [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro
    [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse
    [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Include
    [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Foreach
    [INFO] Created: 20 parsers.
    [INFO] Velocimacro : initialization starting.
    [INFO] Velocimacro : adding VMs from VM library template : VM_global_library.vm
    [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in any resource loader.
    [INFO] Velocimacro : error using  VM library template VM_global_library.vm : org.apache.velocity.exception.ResourceNotFoundException: Unable to find resource 'VM_global_library.vm'
    [INFO] Velocimacro :  VM library template macro registration complete.
    [INFO] Velocimacro : allowInline = true : VMs can be defined inline in templates
    [INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may NOT replace previous VM definitions
    [INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be  global in scope if allowed.
    [INFO] Velocimacro : initialization complete.
    [INFO] Velocity successfully started.
    [INFO] [hpi:create]
    Enter the groupId of your plugin: foo
    [INFO] Defaulting package to group ID: foo
    Enter the artifactId of your plugin: bar
    [INFO] ----------------------------------------------------------------------------
    [INFO] Using following parameters for creating Archetype: maven-hpi-plugin:1.34
    [INFO] ----------------------------------------------------------------------------
    [INFO] Parameter: groupId, Value: foo
    [INFO] Parameter: packageName, Value: foo
    [INFO] Parameter: basedir, Value: /
    [INFO] Parameter: package, Value: foo
    [INFO] Parameter: version, Value: 1.0-SNAPSHOT
    [INFO] Parameter: artifactId, Value: bar
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to create a new Hudson plugin
    
    Embedded error: Error merging velocity templates
    /bar/pom.xml (No such file or directory)
    [INFO] ------------------------------------------------------------------------
    [INFO] Trace
    org.apache.maven.lifecycle.LifecycleExecutionException: Failed to create a new Hudson plugin
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:583)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:512)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:482)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:227)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
            at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
            at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
            at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
            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:585)
            at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
            at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
            at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
            at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
    Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to create a new Hudson plugin
            at org.jvnet.hudson.maven.plugins.hpi.CreateMojo.execute(CreateMojo.java:195)
            at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:451)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
            ... 16 more
    Caused by: org.apache.maven.archetype.ArchetypeTemplateProcessingException: Error merging velocity templates
            at org.apache.maven.archetype.DefaultArchetype.processTemplate(DefaultArchetype.java:876)
            at org.apache.maven.archetype.DefaultArchetype.processTemplate(DefaultArchetype.java:730)
            at org.apache.maven.archetype.DefaultArchetype.processTemplates(DefaultArchetype.java:475)
            at org.apache.maven.archetype.DefaultArchetype.createArchetype(DefaultArchetype.java:329)
            at org.jvnet.hudson.maven.plugins.hpi.CreateMojo.execute(CreateMojo.java:174)
            ... 18 more
    Caused by: java.io.FileNotFoundException: /bar/pom.xml (No such file or directory)
            at java.io.FileOutputStream.open(Native Method)
            at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
            at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
            at org.apache.maven.archetype.DefaultArchetype.processTemplate(DefaultArchetype.java:866)
            ... 22 more
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 20 seconds
    [INFO] Finished at: Mon Apr 13 12:36:16 GMT-05:00 2009
    [INFO] Final Memory: 10M/19M
    [INFO] ------------------------------------------------------------------------
    
    
  20. When following the instructions above, and running mvn hpi:create I receive a message saying that it is missing: com.sun:tools:jar:1.5. When running in debug mode I can see that it is looking for the file C:\Program Files\Java\jdk1.6.0_13\..\lib\tools.jar. Where did the ..\ came from? My JAVA_HOME path is set to C:\Program Files\Java\jdk1.6.0_13. 

    Kindly regards,

    Fredrik

    1. It actually worked fine if I just changed the JAVA_HOME to the jre subfolder.

  21. Unknown User (sbarlow)

    I am running instructions on wndows with java 1.5 on windows with mvn (Apache Maven 2.1.0 (r755702; 2009-03-18 19:10:27+0000)) and I get the following error...

    C:\stuartb\java\HUDSON~1>mvn -e hpi:create
    + Error stacktraces are turned on.
    [INFO] Scanning for projects...
    [INFO] Searching repository for plugin with prefix: 'hpi'.
    [INFO] org.jvnet.hudson.tools: checking for updates from m.g.o-public
    [WARNING] repository metadata for: 'org.jvnet.hudson.tools' could not be retrieved from repository: m.g.o-public due to
    an error: Error transferring file: maven.glassfish.org
    [INFO] Repository 'm.g.o-public' will be blacklisted
    [INFO] org.jvnet.hudson.tools: checking for updates from central
    [WARNING] repository metadata for: 'org.jvnet.hudson.tools' could not be retrieved from repository: central due to an er
    ror: Error transferring file: repo1.maven.org
    [INFO] Repository 'central' will be blacklisted
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] The plugin 'org.apache.maven.plugins:maven-hpi-plugin' does not exist or no valid version could be found
    [INFO] ------------------------------------------------------------------------
    [INFO] Trace
    org.apache.maven.lifecycle.LifecycleExecutionException: The plugin 'org.apache.maven.plugins:maven-hpi-plugin' does not
    exist or no valid version could be found
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.verifyPlugin(DefaultLifecycleExecutor.java:1546)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor(DefaultLifecycleExecutor.java:1786)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.segmentTaskListByAggregationNeeds(DefaultLifecycleExecuto
    r.java:446)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:176)
            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:585)
            at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
            at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
            at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
            at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
    Caused by: org.apache.maven.plugin.version.PluginVersionNotFoundException: The plugin 'org.apache.maven.plugins:maven-hp
    i-plugin' does not exist or no valid version could be found
            at org.apache.maven.plugin.version.DefaultPluginVersionManager.resolvePluginVersion(DefaultPluginVersionManager.
    java:229)
            at org.apache.maven.plugin.version.DefaultPluginVersionManager.resolvePluginVersion(DefaultPluginVersionManager.
    java:91)
            at org.apache.maven.plugin.DefaultPluginManager.verifyPlugin(DefaultPluginManager.java:172)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.verifyPlugin(DefaultLifecycleExecutor.java:1517)
            ... 14 more
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: < 1 second
    [INFO] Finished at: Tue May 26 12:08:54 BST 2009
    [INFO] Final Memory: 1M/3M
    [INFO] ------------------------------------------------------------------------
    C:\stuartb\java\HUDSON~1>
    

    Any thoughts on this?
    Looks like mvn is not all together happy. Possible network issue?
    The path to mvn is strewn with small hurdles. A clever but not simple build process.

    1. Unknown User (sbarlow)

      Solved it! Hudson did not say anytyhing but this was a network proxy issue. Once I had the proxy definded in the settings.xml file everything worked fine.
      Thanks mvn for hiding the real error.

      1. Unknown User (jeffreychyan)

        Can you explain what you did? How do you define the proxy? I'm getting the same error you did but I don't know how to fix it.

  22. Unknown User (gabriel.falkenberg@gmail.com)

    If you get an error like this:

    [INFO] [hpi:apt-compile]
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] JDK6 or later is necessary to build a Hudson plugin
    [INFO] ------------------------------------------------------------------------
    

    when compiling on OS X even though java -version says you are using Java > 1.6 you might need to set JAVA_HOME manually to /System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home or something like that, to be sure that maven uses JDK6.

  23. Unknown User (olaponken)

    I have a problem with running/debugging my plugin. I have set up everything according to the guide and it compiles nicely. I can even create a .hpi-package and install in Hudson with the tutorial. But I can't seem to debug.

    I try to run "mvn hpi:run" which shows some output and from what I can see everything goes well, but I can't connect to localhost?

    Anyone that know what I have done wrong?

  24. Hi,

     I am totally new to hudson and want to write a plugin. So I followed the instructions on this site and did the following:

    01. Downloaded Maven 2.2.0

    02. Modified the Maven settings.xml file due to the xml snippet described on this page

    03. Want to setup a new plugin with mvn hpi:create

    The third step failed with the error message:

    [INFO] Internal error in the plugin manager executing goal 'org.jvnet.hudson.tools:maven-hpi-plugin:1.40:create': Unable to load the mojo 'org.jvnet.hudson.
    tools:maven-hpi-plugin:1.40:create' in the plugin 'org.jvnet.hudson.tools:maven-hpi-plugin'. A required class is missing: Lorg/apache/maven/archetype/Archetype; org.apache.maven.archetype.Archetype

    To resolve this problem I checked whether the class 'Archetype' is in the Maven repository on my disk. I found a directory in %USERPROFILE%\.m2\repository\org\apache\maven\archetype so I thought that I have to add this path to any Maven configuration file or something like this.

    Could anybody give me some suggestions or some keywords where I could read on to get started on writing the plugin?

    Kind regards,

    Heiko

    1. Unknown User (cameronf)

      Hi,

      I am having the exact same issue with the exact same error.
      When I check the ~/.m2 directory there is no archetype directory in ~/.m2/repository/org/apache/maven

      I'm new to Maven and Hudson plugin development, so it could easily be a rookie mistake.

      Thoughts?

  25. Everything builds as described, but I can't get the plugin to show up anywhere in the running Hudson apart from on the installed plugins pages.

     What am I missing please?

    1. Unknown User (christophe.furmaniak@gmail.com)

      If you are an eclipse user and that you used mvn eclipse:eclipse, check the JDK compliance of your project. It is set by default to 1.5 but you have to force it to 1.6 and it will work.

    2. I know this is an old thread, but this might save some time for other newbies - I ran into this same problem and I was able to solve it by removing my custom groupId from the pom.

      Kolos

  26. Unknown User (russ.hickingbottom@gmail.com)

    I am in the same boat as Adrian - I have it built, I have it installed but I don't see anywhere where this manifests itself in my hudson instance?  Any ideas?  I checked my eclipse project and it is JDK 1.6 compliant.

    Any help would be appreciated.

    1. Unknown User (blaine)

      An I am in the same boat as Adrian and Russ, a year later.

      Christophe's suggestion doesn't help me as I am not using any IDE.  I'm using command line with OpenJDK 1.6 (except that for my standalone Hudson webapp I'm running Tomcat 6 with Sun JDK 1.6).

      I have the same exact situation as Adrian Smith explained, regardless whether I use "mvn...: run" or install the .hpi into a standalone Hudson webapp.

      As the problem persists after  year and a half, surely others will continue to run into this.  Could somebody give us a clue about where we should see the plugin in the Hudson UI?  Like on which Hudson page(s).  Seeing that the new plugin is a "Builder", I expected to see a new item on the Hudson "New Job" page, but I do not.

      I'm a tutorial writer, and I don't understand why somebody would dedicate the time to write one but end at the installation step-- giving no hint about how to use or verify the final product.

      1. Unknown User (blaine)

        Sorry to self-reply, but I wanted to report back that my issues are resolved.

        The reason it took me so long is that Hudson either does very little validation of installed plugins, or that validation is poor.  Hudson has no idea when incompatible and non-functional plugins are installed.

        The answer to my primary question is, when a plugin is installed successfully, a stanza for that plugin will appear in the global config page ("Configure System" link, URL /CONTEXT-ROOT/configure).  I deduced this after reading one of the Confluence pages about Jelly.

        My problems were due to not-knowing-where-to-look, compounded by building an incompatible version of the plugin.  When installing the plugin whose source was incompatible with my Hudson web app, the plugin did install but was crippled and did not appear on the global config screen.

        1. Any chance you could share exactly how your plugin was incompatible and how you fixed it (or did you?)

          I'm trying to build a plugin that is based on an existing (working) plugin, it does not show up but I have no idea how to debug it.

          1. I also couldn't find hello world builder in the global config page at the beginning. But I change the version of jenkins in pom.xml to the newest one and rerun it, then it works. 

            <groupId>org.jenkins-ci.plugins</groupId>

                <artifactId>plugin</artifactId>

                <version>1.457</version><!-- which version of Jenkins is this plugin built against? --> 

  27. Unknown User (vedran)

    Hi,

    is there an update on the issue with missing class AnnotationProcessorFactory?
    I used the hpi archetype from within Eclipse and set the version of the parent pom to the version I use of Hudson (also tried 1.323 and 1.310):

    <parent>
    <groupId>org.jvnet.hudson.plugins</groupId>
    <artifactId>plugin</artifactId>
    <version>1.329</version>
    </parent>

    What I get is similar to a former post here (it had no resolution):

    Internal error in the plugin manager executing goal 'org.jvnet.hudson.tools:maven-hpi-plugin:1.45:apt-compile': Unable to load the mojo 'org.jvnet.hudson.tools:maven-hpi-plugin:1.45:apt-compile' in the plugin 'org.jvnet.hudson.tools:maven-hpi-plugin'. A required class is missing: com/sun/mirror/apt/AnnotationProcessorFactory

    Does anyone have a hint for me?

    Thanks, Vedran

    1. Unknown User (vedran)

      After some deeper analysis, the problem was related to my JVM. It's slightly different and missed that class. Need to find out why, but since the hpi plugins expect the above mentioned class to be present they couldn't work in my case. Maybe declaring an explicit dependency could improve the situation? I found the class also in other artifacts on Maven Central and Glassfish (which first confused me), so others have repackaged the stuff (it's not strictly part of the main runtime libraries, but the apt tools library). Ok, that was just fyi. Cheers, Vedran

      1. Unknown User (sveyrie)

        Hello Vedran,

        I just started a plugin project with the tutorial, and had exactly the same problem, so it is (probably) not specific of your installation.

        1. Unknown User (vedran)

          Hi Sylvain, at least in my case switching back to Sun Hotspot JVM of jdk1.6.0_16 fixed the problem immediately and it works now for me. Regards, Vedran

          1. Unknown User (sveyrie)

            OK, after investigation, the issue for me is from Eclipse IAM (Maven integration) that does not include JDK jars (only JRE), so tools.jar is not included, even if everything is pointing on the JDK. Its a classical Eclipse/JRE/JDK classpath hell. It is not a hudson maven packaging issue (command-line maven works fine in all cases).

  28. I created a new plugin using mvn -cpu hpi:create which went fine. The plugin worked for a while and I could modify it, adding new things and whatnot, but eventually I ended up with the following error. I also ended up with the error if I left the plugin untouched and just rebuilt it frequently. mvn clean does nothing to help the situation.

    [INFO] Compiling 6 source files to /home/thomas/Development/Java/Workspace/WorkOrder/test/target/classes
    Note: Generating com/thomaspwilson/HelloWorldBuilder.stapler
    Note: Generating com/thomaspwilson/HelloWorldBuilder/DescriptorImpl/doCheckName.stapler
    /home/thomas/Development/Java/Workspace/WorkOrder/test/src/main/java/com/thomaspwilson/HelloWorldBuilder.java:35: com.thomaspwilson.HelloWorldBuilder clashes with package of same name
    public class HelloWorldBuilder extends Builder {
           ^
    /home/thomas/Development/Java/Workspace/WorkOrder/test/target/generated-sources/localizer/com/thomaspwilson/HelloWorldBuilder/Messages.java:3: package com.thomaspwilson.HelloWorldBuilder clashes with class of same name
    package com.thomaspwilson.HelloWorldBuilder;
    ^
    /home/thomas/Development/Java/Workspace/WorkOrder/test/src/main/java/com/thomaspwilson/HelloWorldBuilder.java:35: com.thomaspwilson.HelloWorldBuilder clashes with package of same name
    public class HelloWorldBuilder extends Builder {
           ^
    /home/thomas/Development/Java/Workspace/WorkOrder/test/target/generated-sources/localizer/com/thomaspwilson/HelloWorldBuilder/Messages.java:3: package com.thomaspwilson.HelloWorldBuilder clashes with class of same name
    package com.thomaspwilson.HelloWorldBuilder;
    ^
    

    Does anyone have any ideas?

  29. Unknown User (manoharsj)

    Hello  All,

    Greetings for the day.

    I am working on Hudson Plugin developement.

    Following steps i followed to develope huson plugin.

    1. installed maven 2.2.1

    2. executed command mvn -e -cpu  hpi:create

    3. It failed to complete with following exception. I would be good if you please help me.

    [WARNING] *** CHECKSUM FAILED - Checksum failed on download: local = '9af237d289
    6530e8d4d661e448d0d46fe3783491'; remote = '0de20e1eea680fc277fddb66bc24ba40d4491
    68b' - IGNORING
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Internal error in the plugin manager executing goal 'org.jvnet.hudson.too
    ls:maven-hpi-plugin:1.51:create': Unable to load the mojo 'org.jvnet.hudson.tool
    s:maven-hpi-plugin:1.51:create' in the plugin 'org.jvnet.hudson.tools:maven-hpi-
    plugin'. A required class is missing: Lorg/apache/maven/archetype/Archetype;
    [INFO] ------------------------------------------------------------------------

    Can anyone please help me on this.. Thanks in Advance.

    Manohar

  30. When I do this: 

    $ cd newly-created-directory

    $ mvn package

    I can download almost everything but then I get this error:

    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to resolve artifact.

    Missing:
    ----------
    1) org.jvnet.hudson.main:hudson-war:war:1.319

      Try downloading the file manually from the project website.

      Then, install it using the command:
          mvn install:install-file -DgroupId=org.jvnet.hudson.main -DartifactId=hudson-war -Dversion=1.319 -Dpackaging=war -Dfile=/path/to/file

      Alternatively, if you host your own repository you can deploy the file there:
          mvn deploy:deploy-file -DgroupId=org.jvnet.hudson.main -DartifactId=hudson-war -Dversion=1.319 -Dpackaging=war -Dfile=/path/to/file -Durl=[url] -Dreposito
    ryId=[id]

      Path to dependency:
            1) org.jvnet.hudson.plugins:email-ext:hpi:2.6-SNAPSHOT
            2) org.jvnet.hudson.main:hudson-war:war:1.319

    2) org.jvnet.hudson.main:hudson-war:jar:war-for-test:1.319

      Try downloading the file manually from the project website.

      Then, install it using the command:
          mvn install:install-file -DgroupId=org.jvnet.hudson.main -DartifactId=hudson-war -Dversion=1.319 -Dclassifier=war-for-test -Dpackaging=jar -Dfile=/path/to
    /file

      Alternatively, if you host your own repository you can deploy the file there:
          mvn deploy:deploy-file -DgroupId=org.jvnet.hudson.main -DartifactId=hudson-war -Dversion=1.319 -Dclassifier=war-for-test -Dpackaging=jar -Dfile=/path/to/f
    ile -Durl=[url] -DrepositoryId=[id]

      Path to dependency:
            1) org.jvnet.hudson.plugins:email-ext:hpi:2.6-SNAPSHOT
            2) org.jvnet.hudson.main:hudson-test-harness:jar:1.319
            3) org.jvnet.hudson.main:hudson-war:jar:war-for-test:1.319

    ----------
    2 required artifacts are missing.

    for artifact:
      org.jvnet.hudson.plugins:email-ext:hpi:2.6-SNAPSHOT

    from the specified remote repositories:
      m.g.o-public (http://maven.glassfish.org/content/groups/public/),
      central (http://repo1.maven.org/maven2)

    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 27 minutes 56 seconds
    [INFO] Finished at: Wed May 05 12:55:50 CEST 2010
    [INFO] Final Memory: 29M/69M
    [INFO] ------------------------------------------------------------------------

    So my question is what am I missing? I have tried diffrent plugin releases but still get the same error

  31. Unknown User (blaine)

    Not fatal to the tutorial, since I can use the (very) long Maven plugin strings, but the Setting Up Environment step above is completely useless for me.  Although I have put the setup.xml file in place, the mvn commands only work if I give the long strings.  I.e., hpi:ANYTHING does not work.

    As required by the instructions here, I am using a fairly recent version of Maven (ie. 2.0.9 or newer). Namely 3.0.1 (which they say is backwards compatible and still uses $HOME/.m2/setup.xml).  As of today, this is the main public release of Maven and the one recommended by the Maven project.

    Warning

    If (like me) you can't use short Maven plugin strings, do not supply a version number like "1.23" in the tutorial unless you really want to work with an old version of Hudson.

    If you want to deploy the .hpi to an app server and are running a recent Hudson distribution webapp, you will want to get the latest version of plugin source by specifying no version label.

  32. Unknown User (blaine)

    The Building a Plugin section above is useless for the purpose stated.

    mvn package

    does build the .hpi file at the indicated location, so

    mvn install

    is completely unnecessary for that purpose.

  33. For chapter setting up environment , in nexus hints, "you can ignore these instructions" it leads misunderstanding, since I think no matter nexus or not, we still need to set "org.jvnet.hudson.tools" for plugins group in settings.xml

  34. I cannot run hpi:create target if settings.xml contains:

        <pluginGroup>org.jenkins-ci.tools</pluginGroup>
        <pluginGroup>org.jenkins-ci.tools</pluginGroup>

    get error:

    $ mvn -e -cpu hpi:create

    + Error stacktraces are turned on.

    [INFO] Scanning for projects...

    [INFO] Searching repository for plugin with prefix: 'hpi'.

    [INFO] ------------------------------------------------------------------------

    [ERROR] BUILD ERROR

    [INFO] ------------------------------------------------------------------------

    [INFO] The plugin 'org.apache.maven.plugins:maven-hpi-plugin' does not exist or no valid version could be found

    [INFO] ------------------------------------------------------------------------

    [INFO] Trace

    org.apache.maven.lifecycle.LifecycleExecutionException: The plugin 'org.apache.maven.plugins:maven-hpi-plugin' does not

    exist or no valid version could be found

            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.verifyPlugin(DefaultLifecycleExecutor.java:1569)

    works fine with:

        <pluginGroup>org.jvnet.hudson.tools</pluginGroup>

    1. <settings>
       <!- Added Jenkins repositories ->
       <profiles>
         <profile>
           <id>jenkins</id>
           <activation>
             <activeByDefault>true</activeByDefault>
           </activation>
           <repositories>
             <repository>
               <id>java.net-m2-repository</id>
               <url>http://maven.jenkins-ci.org:8081/content/repositories/releases/
               </url>
             </repository>
           </repositories>
           <pluginRepositories>
             <pluginRepository>
               <id>jenkins-m2-repository</id>
               <name>Jenkins Plugin Repository</name>
               <url>http://maven.jenkins-ci.org:8081/content/repositories/releases/</url>
               <layout>default</layout>
             </pluginRepository>
           </pluginRepositories>
         </profile>
       </profiles>
       <pluginGroups>
         <pluginGroup>org.jenkins-ci.tools</pluginGroup>
       </pluginGroups>
      <!-- Hudson plugin group 
         <pluginGroups>
          <pluginGroup>org.jvnet.hudson.tools</pluginGroup>
        </pluginGroups>
      -->
      </settings>
      Thanks to Vojtech Juranek, here is working version of settings.xml:

      <settings>

       <!- Added Jenkins repositories ->

       <profiles>

         <profile>

           <id>jenkins</id>

           <activation>

             <activeByDefault>true</activeByDefault>

           </activation>

           <repositories>

             <repository>

               <id>java.net-m2-repository</id>

               <url>http://maven.jenkins-ci.org:8081/content/repositories/releases/

               </url>

             </repository>

           </repositories>

           <pluginRepositories>

             <pluginRepository>

               <id>jenkins-m2-repository</id>

               <name>Jenkins Plugin Repository</name>

               <url>http://maven.jenkins-ci.org:8081/content/repositories/releases/</url>

               <layout>default</layout>

             </pluginRepository>

           </pluginRepositories>

         </profile>

       </profiles>

       <pluginGroups>

         <pluginGroup>org.jenkins-ci.tools</pluginGroup>

       </pluginGroups>

      <!-- Hudson plugin group 

         <pluginGroups>

          <pluginGroup>org.jvnet.hudson.tools</pluginGroup>

        </pluginGroups>

      -->

      </settings>

  35. Our Jenkins is in a DMZ, where we can't have acces to the jekins-ci.orh maven repo. We haven our own nexus server  mirroing jenkins nexus. We can access our own nexus, where all jenkins plugins are mirrored. How can we creat an "update-center.json" file with our nexus domain url?

  36. Ok so after many attempts on both 2.2.1 and 3.0.x I always get the same inexplicable JellyTestSuiteBuilder error in the "tests" phase.

    C:\eclipse\eclipse\stuff\aaaaaaahhh>mvn package \-e
    + Error stacktraces are turned on.
    \[INFO\] Scanning for projects...
    \[INFO\] \-----------------------------------------------------------------------\-
    \[INFO\] Building Unnamed - gggahhhh:aaaaaaahhh:hpi:1.0-SNAPSHOT
    \[INFO\] task-segment: \[package\]
    \[INFO\] \-----------------------------------------------------------------------\-
    \[INFO\] \[enforcer:display-info {execution: default}\]
    \[INFO\] Maven Version: 2.2.1
    \[INFO\] JDK Version: 1.6.0_26 normalized as: 1.6.0-26
    \[INFO\] OS Info: Arch: x86 Family: windows Name: windows xp Version: 5.1
    \[INFO\] \[localizer:generate {execution: default}\]
    \[INFO\] \[resources:resources {execution: default-resources}\]
    \[WARNING\] Using platform encoding (Cp1252 actually) to copy filtered resources,
    i.e. build is platform dependent\!
    \[INFO\] Copying 4 resources
    \[INFO\] \[hpi:apt-compile {execution: default-apt-compile}\]
    \[INFO\] Nothing to compile - all classes are up to date
    \[INFO\] \[access-modifier-checker:enforce {execution: default-enforce}\]
    \[INFO\] \[hpi:insert-test {execution: default-insert-test}\]
    \[INFO\] \[groovy:generateTestStubs {execution: test-in-groovy}\]
    \[INFO\] No sources found for Java stub generation
    \[INFO\] \[resources:testResources {execution: default-testResources}\]
    \[WARNING\] Using platform encoding (Cp1252 actually) to copy filtered resources,
    i.e. build is platform dependent\!
    \[INFO\] skip non existing resourceDirectory C:\eclipse\eclipse\stuff\aaaaaaahhh\s
    rc\test\resources
    \[INFO\] \[compiler:testCompile {execution: default-testCompile}\]
    \[INFO\] Nothing to compile - all classes are up to date
    \[INFO\] \[hpi:test-hpl {execution: default-test-hpl}\]
    \[INFO\] Generating C:\eclipse\eclipse\stuff\aaaaaaahhh\target\test-classes\the.hp
    l
    \[INFO\] \[hpi:resolve-test-dependencies {execution: default-resolve-test-dependenc
    ies}\]
    \[INFO\] \[groovy:testCompile {execution: test-in-groovy}\]
    \[INFO\] No sources found to compile
    \[WARNING\] DEPRECATED \[systemProperties\]: Use systemPropertyVariables instead.
    \[INFO\] \[surefire:test {execution: default-test}\]
    \[INFO\] Surefire report directory: C:\eclipse\eclipse\stuff\aaaaaaahhh\target\sur
    efire-reports
    
    \------------------------------------------------------\-
    &nbsp;T E S T S
    \------------------------------------------------------\-
    Running InjectedTest
    Exploding jenkins.war at \Redirected$\mlemay\.m2\repository\org\jenkins-ci\main\
    jenkins-war\1.399\jenkins-war-1.399-war-for-test.jar
    Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 1.437 sec <<< FA
    ILURE\!
    
    Results :
    
    Tests in error:
     org.jvnet.hudson.test.JellyTestSuiteBuilder$JellyTestSuite(org.jvnet.hudson.te
    st.junit.FailedTest): Failed to initialize exploded war
    
    Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
    
    \[INFO\] \-----------------------------------------------------------------------\-
    \[ERROR\] BUILD FAILURE
    \[INFO\] \-----------------------------------------------------------------------\-
    \[INFO\] There are test failures.
    
    Please refer to C:\eclipse\eclipse\stuff\aaaaaaahhh\target\surefire-reports for
    the individual test results.
    \[INFO\] \-----------------------------------------------------------------------\-
    \[INFO\] Trace
    org.apache.maven.BuildFailureException: There are test failures.
    
    Please refer to C:\eclipse\eclipse\stuff\aaaaaaahhh\target\surefire-reports for
    the individual test results.
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
    ultLifecycleExecutor.java:715)
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLi
    fecycle(DefaultLifecycleExecutor.java:556)
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
    ltLifecycleExecutor.java:535)
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
    dleFailures(DefaultLifecycleExecutor.java:387)
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
    ts(DefaultLifecycleExecutor.java:348)
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
    fecycleExecutor.java:180)
     at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
     at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
     at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
     at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
    0)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.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 org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
    
     at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
    Caused by: org.apache.maven.plugin.MojoFailureException: There are test failures
    .
    
    Please refer to C:\eclipse\eclipse\stuff\aaaaaaahhh\target\surefire-reports for
    the individual test results.
     at org.apache.maven.plugin.surefire.SurefireHelper.reportExecution(Suref
    ireHelper.java:74)
     at org.apache.maven.plugin.surefire.SurefirePlugin.execute(SurefirePlugi
    n.java:642)
     at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi
    nManager.java:490)
     at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
    ultLifecycleExecutor.java:694)
     ... 17 more
    \[INFO\] \-----------------------------------------------------------------------\-
    \[INFO\] Total time: 52 seconds
    \[INFO\] Finished at: Fri Jun 17 16:52:40 EDT 2011
    \[INFO\] Final Memory: 46M/110M
    \[INFO\] \-----------------------------------------------------------------------\-
    

    (sorry about the escape chars) Any help at all would be much appreciated.

    1. For the record the cause of this problem was that the repo directory was, by default, on the network. The solution was making it local.

  37. Hi, This may be a dumb problem, but I can't seem to build any plug-in from source.

    I followed the instructions on this page: installed Maven 3.0.3, edited the settingx.xml as instructed on this page, got the source for the Doxygen plug-in, ran 'mvn install' waited for a bit for all the packages to be downloaded and I finally got this:

     C:\Temp\jenkinsci-doxygen-plugin-197189b>mvn install
    [INFO] Scanning for projects...
    [INFO]
    [INFO] ------------------------------------------------------------------------
    [INFO] Building Jenkins Doxygen Plug-in 0.9
    [INFO] ------------------------------------------------------------------------
    [INFO]
    [INFO] --- maven-enforcer-plugin:1.0:display-info (default) @ doxygen ---
    [INFO] Maven Version: 3.0.3
    [INFO] JDK Version: 1.7.0 normalized as: 1.7.0
    [INFO] OS Info: Arch: x86 Family: windows Name: windows xp Version: 5.1
    [INFO]
    [INFO] --- maven-localizer-plugin:1.8:generate (default) @ doxygen ---
    [INFO]
    [INFO] --- maven-resources-plugin:2.4.3:resources (default-resources) @ doxygen
    ---
    [WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources,
    i.e. build is platform dependent!
    [INFO] Copying 3 resources
    [INFO]
    [INFO] --- maven-hpi-plugin:1.64:apt-compile (default-apt-compile) @ doxygen ---
    
    Aug 26, 2011 9:11:33 AM org.sonatype.guice.bean.reflect.NamedClass
    WARNING: Error injecting: org.jvnet.hudson.maven.plugins.hpi.AptCompiler
    java.lang.NoClassDefFoundError: com/sun/mirror/apt/AnnotationProcessorFactory
            at java.lang.Class.getDeclaredConstructors0(Native Method)
            at java.lang.Class.privateGetDeclaredConstructors(Class.java:2404)
            at java.lang.Class.getDeclaredConstructors(Class.java:1853)
            at com.google.inject.spi.InjectionPoint.forConstructorOf(InjectionPoint.
    java:243)
            at com.google.inject.internal.ConstructorBindingImpl.create(ConstructorB
    indingImpl.java:96)
            at com.google.inject.internal.InjectorImpl.createUninitializedBinding(In
    jectorImpl.java:628)
            at com.google.inject.internal.InjectorImpl.createJustInTimeBinding(Injec
    torImpl.java:835)
            at com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecurs
    ive(InjectorImpl.java:769)
            at com.google.inject.internal.InjectorImpl.getJustInTimeBinding(Injector
    Impl.java:254)
            at com.google.inject.internal.InjectorImpl.getBindingOrThrow(InjectorImp
    l.java:205)
            at com.google.inject.internal.InjectorImpl.getInternalFactory(InjectorIm
    pl.java:843)
            at com.google.inject.internal.InjectorImpl.getProviderOrThrow(InjectorIm
    pl.java:957)
            at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java
    :990)
            at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java
    :951)
            at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java
    :1003)
            at org.sonatype.guice.bean.reflect.AbstractDeferredClass.get(AbstractDef
    erredClass.java:47)
            at com.google.inject.internal.InternalFactoryToProviderAdapter.get(Inter
    nalFactoryToProviderAdapter.java:40)
            at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(Pr
    oviderToInternalFactoryAdapter.java:46)
            at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.ja
    va:1021)
            at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(Provi
    derToInternalFactoryAdapter.java:40)
            at com.google.inject.Scopes$1$1.get(Scopes.java:59)
            at com.google.inject.internal.InternalFactoryToProviderAdapter.get(Inter
    nalFactoryToProviderAdapter.java:40)
            at com.google.inject.internal.InjectorImpl$4$1.call(InjectorImpl.java:96
    8)
            at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.ja
    va:1014)
            at com.google.inject.internal.InjectorImpl$4.get(InjectorImpl.java:964)
            at org.sonatype.guice.bean.locators.LazyBeanEntry.getValue(LazyBeanEntry
    .java:79)
            at org.sonatype.guice.plexus.locators.LazyPlexusBean.getValue(LazyPlexus
    Bean.java:53)
            at java.util.AbstractMap.get(AbstractMap.java:182)
            at org.codehaus.plexus.compiler.manager.DefaultCompilerManager.getCompil
    er(DefaultCompilerManager.java:54)
            at org.jvnet.hudson.maven.plugins.hpi.AbstractCompilerMojo.execute(Abstr
    actCompilerMojo.java:260)
            at org.jvnet.hudson.maven.plugins.hpi.CompilerMojo.execute(CompilerMojo.
    java:111)
            at org.jvnet.hudson.maven.plugins.hpi.AptMojo.execute(AptMojo.java:24)
            at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(Default
    BuildPluginManager.java:101)
            at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor
    .java:209)
            at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor
    .java:153)
            at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor
    .java:145)
            at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProje
    ct(LifecycleModuleBuilder.java:84)
            at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProje
    ct(LifecycleModuleBuilder.java:59)
            at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBu
    ild(LifecycleStarter.java:183)
            at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(Lifecycl
    eStarter.java:161)
            at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
            at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
            at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
            at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
            at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:57)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:601)
            at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Laun
    cher.java:290)
            at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.jav
    a:230)
            at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(La
    uncher.java:409)
            at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:
    352)
    Caused by: java.lang.ClassNotFoundException: com.sun.mirror.apt.AnnotationProces
    sorFactory
            at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(
    SelfFirstStrategy.java:50)
            at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm
    .java:244)
            at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm
    .java:230)
            ... 53 more
    
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 4.797s
    [INFO] Finished at: Fri Aug 26 09:11:33 EEST 2011
    [INFO] Final Memory: 9M/23M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.jenkins-ci.tools:maven-hpi-plugin:1.64:apt-co
    mpile (default-apt-compile) on project doxygen: Execution default-apt-compile of
     goal org.jenkins-ci.tools:maven-hpi-plugin:1.64:apt-compile failed: Guice provi
    sion errors:
    [ERROR]
    [ERROR] 1) Error injecting: org.jvnet.hudson.maven.plugins.hpi.AptCompiler
    [ERROR] at ClassRealm[plugin>org.jenkins-ci.tools:maven-hpi-plugin:1.64, parent:
     sun.misc.Launcher$AppClassLoader@2a340e]
    [ERROR] at ClassRealm[plugin>org.jenkins-ci.tools:maven-hpi-plugin:1.64, parent:
     sun.misc.Launcher$AppClassLoader@2a340e]
    [ERROR] while locating org.codehaus.plexus.compiler.Compiler annotated with @com
    .google.inject.name.Named(value=hpi-apt)
    [ERROR]
    [ERROR] 1 error: com/sun/mirror/apt/AnnotationProcessorFactory: com.sun.mirror.a
    pt.AnnotationProcessorFactory
    [ERROR] -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit
    ch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please rea
    d the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutio
    nException
    

    At this point, I am baffled. I tried to compile other plugins, but I get the same error. Any ideas?

    Thanks.

    1. I've been battling the same issue for the past couple of days on Arch Linux. It used to work ok.

      $ java -version
      java version "1.7.0"
      Java(TM) SE Runtime Environment (build 1.7.0-b147)
      Java HotSpot(TM) 64-Bit Server VM (build 21.0-b17, mixed mode)
      $ /opt/maven/bin/mvn -v
      Apache Maven 3.0.3 (rNON-CANONICAL_2011-03-19_21-46_root; 2011-03-20 10:46:53+1300)
      Maven home: /opt/maven
      Java version: 1.7.0, vendor: Oracle Corporation
      Java home: /opt/java/jre
      Default locale: en_US, platform encoding: UTF-8
      OS name: "linux", version: "2.6.39-arch", arch: "amd64", family: "unix"

      Any tips on how to advance from here are greatly appreciated

      1. I found the issue. Summarized from this thread : JDK version 7 has removed an API depended on by apt-compile. Fixed by depending on a newer jenkins plugin pom.xml.

        1. To depend on a newer jenkins plugin:

          After running mvn hpi:create go into the new folder (called whatever your entered for artifactID) and modify the pom.xml file. The section of interest is:

          <parent>
              <groupId>org.jenkins-ci.plugins</groupId>
              <artifactId>plugin</artifactId>
              <version>1.399</version><!-- which version of Jenkins is this plugin built against? -->  
          </parent>
          

          Change the version to something more recent. I used 1.437 at the time of writing.

          Having never used maven, how to depend on a newer jenkins plugin pom.xml was not clear to me.

  38. Hi, I'm using Maven with Eclipse and I don't have a mvn executable because Maven is integrated in the Eclipse plugin structure.

    But I have a "New Maven Project" wizard in Eclipse. Does someone know how to create new Maven plugins suitable for Jenkins with this Maven-Eclipse-Integration (i.e. without the need for a standalone maven command-line version)?

  39. I get following error, multiple attempts.

    HTTP ERROR: 500INTERNAL_SERVER_ERRORRequestURI=/job/test/configSubmit

    Caused by:java.lang.UnsupportedOperationException

    at org.jvnet.hudson.test.HudsonTestCase$TestBuildWrapper$TestBuildWrapperDescriptor.newInstance(HudsonTestCase.java:1962)
    at org.jvnet.hudson.test.HudsonTestCase$TestBuildWrapper$TestBuildWrapperDescriptor.newInstance(HudsonTestCase.java:1953)
    at hudson.util.DescribableList.rebuild(DescribableList.java:154)
    at hudson.model.Project.submit(Project.java:196)
    at hudson.model.Job.doConfigSubmit(Job.java:989)

  40. Unknown User (jamiec)

    Let's take a look at the source code. A plugin's main entry point is a PluginImpl class that extends from Plugin.

    Hey all, just getting started here and I've been working through this tutorial... is the above statement still correct? I don't think this matches the source code created by hpi:create any more.

  41. hi i am trying to packaging this project using mvn package but getting one error, here is the stack trace, can anyone please help me in this:

    C:\maven\punit>mvn package -e 
    [INFO] Error stacktraces are turned on. 
    [INFO] Scanning for projects... 
    [INFO] 
    [INFO] ------------------------------------------------------------------------ 
    [INFO] Building punit 1.0-SNAPSHOT 
    [INFO] ------------------------------------------------------------------------ 
    Downloading: http://repo.jenkins-ci.org/public/org/jenkins-ci/main/jenkins-test- 
    harness/1.466/jenkins-test-harness-1.466.jar 
    Downloading: http://repo.jenkins-ci.org/public/org/jenkins-ci/plugins/subversion 
    /1.26/subversion-1.26.jar 
    Downloading: http://repo.jenkins-ci.org/public/org/jenkins-ci/main/jenkins-war/1 
    .466/jenkins-war-1.466.war 
    Downloading: http://repo.jenkins-ci.org/public/org/jenkins-ci/main/jenkins-core/ 
    1.466/jenkins-core-1.466.jar 
    Downloading: http://repo.jenkins-ci.org/public/org/jenkins-ci/main/jenkins-war/1 
    .466/jenkins-war-1.466-war-for-test.jar 
    Downloaded: http://repo.jenkins-ci.org/public/org/jenkins-ci/plugins/subversion/ 
    1.26/subversion-1.26.jar (306 KB at 2.0 KB/sec) 
    [INFO] ------------------------------------------------------------------------ 
    [INFO] BUILD FAILURE 
    [INFO] ------------------------------------------------------------------------ 
    [INFO] Total time: 2:37:14.226s 
    [INFO] Finished at: Sat Sep 15 11:27:04 IST 2012 
    [INFO] Final Memory: 10M/27M 
    [INFO] ------------------------------------------------------------------------ 
    [ERROR] Failed to execute goal on project punit: Could not resolve dependencies 
    for project com.punit:punit:hpi:1.0-SNAPSHOT: The following artifacts could not 
    be resolved: org.jenkins-ci.main:jenkins-war:war:1.466, org.jenkins-ci.main:jenk 
    ins-core:jar:1.466, org.jenkins-ci.main:jenkins-test-harness:jar:1.466, org.jenk 
    ins-ci.main:jenkins-war:jar:war-for-test:1.466: Could not transfer artifact org. 
    jenkins-ci.main:jenkins-war:war:1.466 from/to repo.jenkins-ci.org (http://repo.j 
    enkins-ci.org/public/): GET request of: org/jenkins-ci/main/jenkins-war/1.466/je 
    nkins-war-1.466.war from repo.jenkins-ci.org failed: Read timed out -> [Help 1] 
    org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal o 
    n project punit: Could not resolve dependencies for project com.punit:punit:hpi: 
    1.0-SNAPSHOT: The following artifacts could not be resolved: org.jenkins-ci.main 
    :jenkins-war:war:1.466, org.jenkins-ci.main:jenkins-core:jar:1.466, org.jenkins- 
    ci.main:jenkins-test-harness:jar:1.466, org.jenkins-ci.main:jenkins-war:jar:war- 
    for-test:1.466: Could not transfer artifact org.jenkins-ci.main:jenkins-war:war: 
    1.466 from/to repo.jenkins-ci.org (http://repo.jenkins-ci.org/public/): GET requ 
    est of: org/jenkins-ci/main/jenkins-war/1.466/jenkins-war-1.466.war from repo.je 
    nkins-ci.org failed 
    at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDe 
    pendencies(LifecycleDependencyResolver.java:210) 
    at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.resol 
    veProjectDependencies(LifecycleDependencyResolver.java:117) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAr 
    eResolved(MojoExecutor.java:258) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
    .java:201) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
    .java:153) 
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
    .java:145) 
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProje 
    ct(LifecycleModuleBuilder.java:84) 
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProje 
    ct(LifecycleModuleBuilder.java:59) 
    at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBu 
    ild(LifecycleStarter.java:183) 
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(Lifecycl 
    eStarter.java:161) 
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320) 
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) 
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) 
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) 
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. 
    java:57) 
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces 
    sorImpl.java:43) 
    at java.lang.reflect.Method.invoke(Method.java:601) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Laun 
    cher.java:290) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.jav 
    a:230) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(La 
    uncher.java:409) 
    at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java: 
    352) 
    Caused by: org.apache.maven.project.DependencyResolutionException: Could not res 
    olve dependencies for project com.punit:punit:hpi:1.0-SNAPSHOT: The following ar 
    tifacts could not be resolved: org.jenkins-ci.main:jenkins-war:war:1.466, org.je 
    nkins-ci.main:jenkins-core:jar:1.466, org.jenkins-ci.main:jenkins-test-harness:j 
    ar:1.466, org.jenkins-ci.main:jenkins-war:jar:war-for-test:1.466: Could not tran 
    sfer artifact org.jenkins-ci.main:jenkins-war:war:1.466 from/to repo.jenkins-ci. 
    org (http://repo.jenkins-ci.org/public/): GET request of: org/jenkins-ci/main/je 
    nkins-war/1.466/jenkins-war-1.466.war from repo.jenkins-ci.org failed 
    at org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(D 
    efaultProjectDependenciesResolver.java:189) 
    at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDe 
    pendencies(LifecycleDependencyResolver.java:185) 
    ... 22 more 
    Caused by: org.sonatype.aether.resolution.DependencyResolutionException: The fol 
    lowing artifacts could not be resolved: org.jenkins-ci.main:jenkins-war:war:1.46 
    6, org.jenkins-ci.main:jenkins-core:jar:1.466, org.jenkins-ci.main:jenkins-test- 
    harness:jar:1.466, org.jenkins-ci.main:jenkins-war:jar:war-for-test:1.466: Could 
    not transfer artifact org.jenkins-ci.main:jenkins-war:war:1.466 from/to repo.je 
    nkins-ci.org (http://repo.jenkins-ci.org/public/): GET request of: org/jenkins-c 
    i/main/jenkins-war/1.466/jenkins-war-1.466.war from repo.jenkins-ci.org failed 
    at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveDepe 
    ndencies(DefaultRepositorySystem.java:375) 
    at org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(D 
    efaultProjectDependenciesResolver.java:183) 
    ... 23 more 
    Caused by: org.sonatype.aether.resolution.ArtifactResolutionException: The follo 
    wing artifacts could not be resolved: org.jenkins-ci.main:jenkins-war:war:1.466, 
    org.jenkins-ci.main:jenkins-core:jar:1.466, org.jenkins-ci.main:jenkins-test-ha 
    rness:jar:1.466, org.jenkins-ci.main:jenkins-war:jar:war-for-test:1.466: Could n 
    ot transfer artifact org.jenkins-ci.main:jenkins-war:war:1.466 from/to repo.jenk 
    ins-ci.org (http://repo.jenkins-ci.org/public/): GET request of: org/jenkins-ci/ 
    main/jenkins-war/1.466/jenkins-war-1.466.war from repo.jenkins-ci.org failed 
    at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolve(Def 
    aultArtifactResolver.java:538) 
    at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArti 
    facts(DefaultArtifactResolver.java:216) 
    at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveDepe 
    ndencies(DefaultRepositorySystem.java:358) 
    ... 24 more 
    Caused by: org.sonatype.aether.transfer.ArtifactTransferException: Could not tra 
    nsfer artifact org.jenkins-ci.main:jenkins-war:war:1.466 from/to repo.jenkins-ci 
    .org (http://repo.jenkins-ci.org/public/): GET request of: org/jenkins-ci/main/j 
    enkins-war/1.466/jenkins-war-1.466.war from repo.jenkins-ci.org failed 
    at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$4.wrap(W 
    agonRepositoryConnector.java:951) 
    at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$4.wrap(W 
    agonRepositoryConnector.java:941) 
    at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask. 
    run(WagonRepositoryConnector.java:669) 
    at org.sonatype.aether.util.concurrency.RunnableErrorForwarder$1.run(Run 
    nableErrorForwarder.java:60) 
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor
    java:1110) 
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor 
    .java:603) 
    at java.lang.Thread.run(Thread.java:722) 
    Caused by: org.apache.maven.wagon.TransferFailedException: GET request of: org/j 
    enkins-ci/main/jenkins-war/1.466/jenkins-war-1.466.war from repo.jenkins-ci.org 
    failed 
    at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:3 
    49) 
    at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:3 
    10) 
    at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:2 
    87) 
    at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:97) 
    at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61) 
    at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask. 
    run(WagonRepositoryConnector.java:601) 
    ... 4 more 
    Caused by: java.net.SocketTimeoutException: Read timed out 
    at java.net.SocketInputStream.socketRead0(Native Method) 
    at java.net.SocketInputStream.read(SocketInputStream.java:150) 
    at java.net.SocketInputStream.read(SocketInputStream.java:121) 
    at org.apache.maven.wagon.providers.http.httpclient.impl.io.AbstractSess 
    ionInputBuffer.read(AbstractSessionInputBuffer.java:187) 
    at org.apache.maven.wagon.providers.http.httpclient.impl.io.ContentLengt 
    hInputStream.read(ContentLengthInputStream.java:176) 
    at org.apache.maven.wagon.providers.http.httpclient.conn.EofSensorInputS 
    tream.read(EofSensorInputStream.java:138) 
    at org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:493) 

    at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:3 
    39) 
    ... 9 more 
    [ERROR] 
    [ERROR] Re-run Maven using the -X switch to enable full debug logging. 
    [ERROR] 
    [ERROR] For more information about the errors and possible solutions, please rea 
    d the following articles: 
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyReso 
    lutionException 

  42. Hi, I'm interested in learning how to write new plugins for Jenkins,however I am quite new with using Maven.

    I was following this tutorial, when I ran the command:  mvn -U org.jenkins-ci.tools:maven-hpi-plugin:create

    I got the following error messsage. Any ideas? Thanks:

    INFO ------------------------------------------------------------------------
    ERROR BUILD ERROR
    INFO ------------------------------------------------------------------------
    INFO Failed to resolve artifact.

    Missing:
    ----------
    1) com.sun:tools:jar:1.5

      Try downloading the file manually from the project website.

      Then, install it using the command:
          mvn install:install-file -DgroupId=com.sun -DartifactId=tools -Dversion=1.5 -Dpackaging=jar -Dfile=/path/to/file

      Alternatively, if you host your own repository you can deploy the file there:
          mvn deploy:deploy-file -DgroupId=com.sun -DartifactId=tools -Dversion=1.5 -Dpackaging=jar -Dfile=/path/to/file -Durl=url -DrepositoryId=id

      Path to dependency:
            1) org.jenkins-ci.tools:maven-hpi-plugin:maven-plugin:1.95
            2) org.kohsuke.stapler:maven-stapler-plugin:jar:1.16
            3) com.sun:tools:jar:1.5

    ----------
    1 required artifact is missing.

    for artifact:
      org.jenkins-ci.tools:maven-hpi-plugin:maven-plugin:1.95

    from the specified remote repositories:
      repo.jenkins-ci.org (http://repo.jenkins-ci.org/public/),
      central (http://repo1.maven.org/maven2)

    1. A bit of googling and I found the problem: I was using JRE instead of a JDK. The same issue is also discussed here:

      http://jenkins.361315.n4.nabble.com/com-sun-tools-jar-1-5-is-missing-td390964.html

      The versions which I'm using now which works for me are:

      1) apache-maven-3.0.5

      2) jdk1.6.0_43

  43. Hi,

    I have a problem on Eclipse when I want to import a maven jenkins plugin that I created before with mvn cli. I have some errors in my pom.xml

    Have you got any ideas ?

  44. This tutorial directs users to compile with Maven 2, however the feedback I got on the Jenkins google group directed me to use Maven 3 to properly compile the subversion-plugin (https://groups.google.com/forum/?fromgroups=#!topic/jenkinsci-dev/ccolOycM1gI (https://groups.google.com/forum/?fromgroups=#\!topic/jenkinsci-dev/ccolOycM1gI)).  Compilation fails using Maven 2 and JDK 1.6.0_24, but works with Maven 3.0.5.  This could be worth noting in this write-up if it's not a corner-case.

    Thank you,

    Kenny

  45. used the plugin generator http://plugin-generator.jenkins-ci.org to create a starter plugin.

    setup nexus adding the jenkins-ci proxy as described.

    followed instructions on this page for packaging the project:

    mvn package
    [INFO] Scanning for projects...
    [INFO]
    [INFO] ------------------------------------------------------------------------
    [INFO] Building awesome 1.0-SNAPSHOT
    [INFO] ------------------------------------------------------------------------
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 12.026s
    [INFO] Finished at: Sun Jul 07 10:24:51 PDT 2013
    [INFO] Final Memory: 10M/81M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal on project awesome: Could not resolve dependencies for project org.jenkins-ci.plugins:awesome:hpi:1.0-SNAPSHOT: Failure to 
    find org.netbeans.modules:org-netbeans-insane:jar:RELEASE72 in http://localhost:8081/nexus/content/groups/public was cached in the local repository, 
    resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
    
    

    When I browse in nexus I do see the org-netbeans-insane release.

    I deleted the cached copy under ~/.m2/repository then re-running mvn and mvn still can not find the org-netbreans-insane release.

    this 'awesome' plugin is not awesome.

  46. Hi,

       I started setting up plugin environment, but when i tried to compile am getting the following error. Can you please help me how to overcome it...

    [ERROR] COMPILATION ERROR :
    [INFO] -------------------------------------------------------------
    [ERROR] error: error reading C:\Documents and Settings\Administrator\.m2\repository\org\jenkin
    s-ci\main\jenkins-core\1.509.2\jenkins-core-1.509.2.jar; error in opening zip file
    [ERROR] error: error reading C:\Documents and Settings\Administrator\.m2\repository\org\jenkin
    s-ci\main\jenkins-core\1.509.2\jenkins-core-1.509.2.jar; error in opening zip file
    [INFO] 2 errors
    [INFO] -------------------------------------------------------------
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 8.110s
    [INFO] Finished at: Tue Aug 06 18:28:19 GMT+05:30 2013
    [INFO] Final Memory: 19M/46M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.5:compile (def
    ault-compile) on project build: Compilation failure: Compilation failure:
    [ERROR] error: error reading C:\Documents and Settings\Administrator\.m2\repository\org\jenkin
    s-ci\main\jenkins-core\1.509.2\jenkins-core-1.509.2.jar; error in opening zip file
    [ERROR] error: error reading C:\Documents and Settings\Administrator\.m2\repository\org\jenkin
    s-ci\main\jenkins-core\1.509.2\jenkins-core-1.509.2.jar; error in opening zip file
    [ERROR] -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please read the followin
    g articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

  47. What happened to MartinO's guide?  The link no longer works.

  48. I would like to translate this page into Chinese (Simplified), and add the result under "Other Resources" or other location determined by the community.

    Was wondering if one someone have already done this, thus avoiding duplicate effort,

    or if no one have done it, if it's alright for me to do so, and if it is, where should I post the results.

    Disclaimers:

    One, I'm new to Jenkins

    Two, I don't do translation for a living, thus the translation is a best effort.

    Three, I'm doing this as part of my job to document some project. However, other than the normal "documentation" usage, the company is not going to sell the translation for profit(as far as I know).

    P.S. I couldn't find a obvious place to ask this, so thought to ask it right here on the page.

  49. The online skeleton generator link (http://plugin-generator.jenkins-ci.org/) is broken and gives 404 and has been for a few weeks.

  50. I tried to get in touch with Jenkins plugin develpment using Eclipse following this tutorial and I stuck at an error from maven when creating the Eclipse project, see below.

    Can anyone please help me?

     C:\Users\Paul>mvn -version
    Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T17:41:47+01:00)
    Maven home: C:\apache-maven-3.3.9\bin\..
    Java version: 1.7.0_51, vendor: Oracle Corporation
    Java home: C:\Program Files\Java\jdk1.7.0_51\jre
    Default locale: de_DE, platform encoding: Cp1252
    OS name: "windows 8", version: "6.2", arch: "amd64", family: "windows"
    
    C:\Users\Paul>mvn -DdownloadSources=true -DdownloadJavadocs=true -DoutputDirectory=target/eclipse-classes -Declipse.workspace=workspace eclipse:eclipse eclipse:add-maven-repo
    [INFO] Scanning for projects...
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom (4 KB at 0.3 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom (13 KB at 6.6 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/21/maven-parent-21.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/21/maven-parent-21.pom (26 KB at 11.4 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/apache/10/apache-10.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/apache/10/apache-10.pom (15 KB at 69.1 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.jar (25 KB at 34.5 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom (7 KB at 16.7 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/23/maven-plugins-23.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/23/maven-plugins-23.pom (9 KB at 18.7 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/22/maven-parent-22.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/22/maven-parent-22.pom (30 KB at 69.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/apache/11/apache-11.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/apache/11/apache-11.pom (15 KB at 64.9 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.jar (27 KB at 63.3 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.pom (6 KB at 29.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.7/maven-deploy-plugin-2.7.jar (27 KB at 52.6 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.pom (21 KB at 74.5 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/24/maven-plugins-24.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/24/maven-plugins-24.pom (11 KB at 24.9 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/23/maven-parent-23.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/23/maven-parent-23.pom (32 KB at 67.3 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/apache/13/apache-13.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/apache/13/apache-13.pom (14 KB at 51.7 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-site-plugin/3.3/maven-site-plugin-3.3.jar (122 KB at 212.7 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-antrun-plugin/1.3/maven-antrun-plugin-1.3.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-antrun-plugin/1.3/maven-antrun-plugin-1.3.pom (5 KB at 4.7 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/12/maven-plugins-12.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/12/maven-plugins-12.pom (12 KB at 19.1 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/9/maven-parent-9.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/9/maven-parent-9.pom (33 KB at 91.4 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/apache/4/apache-4.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/apache/4/apache-4.pom (0 B at 0.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-antrun-plugin/1.3/maven-antrun-plugin-1.3.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-antrun-plugin/1.3/maven-antrun-plugin-1.3.jar (24 KB at 51.8 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-5/maven-assembly-plugin-2.2-beta-5.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-5/maven-assembly-plugin-2.2-beta-5.pom (15 KB at 53.8 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/16/maven-plugins-16.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/16/maven-plugins-16.pom (13 KB at 41.5 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/15/maven-parent-15.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/15/maven-parent-15.pom (0 B at 0.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/apache/6/apache-6.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/apache/6/apache-6.pom (0 B at 0.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-5/maven-assembly-plugin-2.2-beta-5.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-5/maven-assembly-plugin-2.2-beta-5.jar (204 KB at 398.4 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.pom (12 KB at 36.8 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-dependency-plugin/2.8/maven-dependency-plugin-2.8.jar (150 KB at 396.8 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.3.2/maven-release-plugin-2.3.2.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.3.2/maven-release-plugin-2.3.2.pom (10 KB at 28.1 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/release/maven-release/2.3.2/maven-release-2.3.2.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/release/maven-release/2.3.2/maven-release-2.3.2.pom (9 KB at 6.6 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.3.2/maven-release-plugin-2.3.2.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-release-plugin/2.3.2/maven-release-plugin-2.3.2.jar (44 KB at 58.5 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml
    Downloaded: https://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml (20 KB at 57.0 KB/sec)
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml (13 KB at 22.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/maven-metadata.xml
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/maven-metadata.xml (741 B at 3.4 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.10/maven-eclipse-plugin-2.10.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.10/maven-eclipse-plugin-2.10.pom (19 KB at 80.6 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/25/maven-plugins-25.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/25/maven-plugins-25.pom (10 KB at 54.5 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/24/maven-parent-24.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/24/maven-parent-24.pom (37 KB at 131.0 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/apache/14/apache-14.pom
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/apache/14/apache-14.pom (15 KB at 78.8 KB/sec)
    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.10/maven-eclipse-plugin-2.10.jar
    Downloaded: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-eclipse-plugin/2.10/maven-eclipse-plugin-2.10.jar (219 KB at 466.7 KB/sec)
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 46.539 s
    [INFO] Finished at: 2015-12-29T11:10:52+01:00
    [INFO] Final Memory: 11M/70M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Could not find goal 'add-maven-repo' in plugin org.apache.maven.plugins:maven-eclipse-plugin:2.10 among available goals clean, configure-workspace, eclipse, help, install-plugins, myeclipse, myeclipse-clean, rad, rad-clean, remove-cache, resolve-workspace-dependencies, to-maven -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoNotFoundException
    
    C:\Users\Paul>mvn -e -X -DdownloadSources=true -DdownloadJavadocs=true -DoutputDirectory=target/eclipse-classes -Declipse.workspace=workspace eclipse:eclipse eclipse:add-maven-repo
    Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T17:41:47+01:00)
    Maven home: C:\apache-maven-3.3.9\bin\..
    Java version: 1.7.0_51, vendor: Oracle Corporation
    Java home: C:\Program Files\Java\jdk1.7.0_51\jre
    Default locale: de_DE, platform encoding: Cp1252
    OS name: "windows 8", version: "6.2", arch: "amd64", family: "windows"
    [DEBUG] Created new class realm maven.api
    [DEBUG] Importing foreign packages into class realm maven.api
    [DEBUG]   Imported: javax.enterprise.inject.* < plexus.core
    [DEBUG]   Imported: javax.enterprise.util.* < plexus.core
    [DEBUG]   Imported: javax.inject.* < plexus.core
    [DEBUG]   Imported: org.apache.maven.* < plexus.core
    [DEBUG]   Imported: org.apache.maven.artifact < plexus.core
    [DEBUG]   Imported: org.apache.maven.classrealm < plexus.core
    [DEBUG]   Imported: org.apache.maven.cli < plexus.core
    [DEBUG]   Imported: org.apache.maven.configuration < plexus.core
    [DEBUG]   Imported: org.apache.maven.exception < plexus.core
    [DEBUG]   Imported: org.apache.maven.execution < plexus.core
    [DEBUG]   Imported: org.apache.maven.execution.scope < plexus.core
    [DEBUG]   Imported: org.apache.maven.lifecycle < plexus.core
    [DEBUG]   Imported: org.apache.maven.model < plexus.core
    [DEBUG]   Imported: org.apache.maven.monitor < plexus.core
    [DEBUG]   Imported: org.apache.maven.plugin < plexus.core
    [DEBUG]   Imported: org.apache.maven.profiles < plexus.core
    [DEBUG]   Imported: org.apache.maven.project < plexus.core
    [DEBUG]   Imported: org.apache.maven.reporting < plexus.core
    [DEBUG]   Imported: org.apache.maven.repository < plexus.core
    [DEBUG]   Imported: org.apache.maven.rtinfo < plexus.core
    [DEBUG]   Imported: org.apache.maven.settings < plexus.core
    [DEBUG]   Imported: org.apache.maven.toolchain < plexus.core
    [DEBUG]   Imported: org.apache.maven.usability < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.* < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.authentication < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.authorization < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.events < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.observers < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.proxy < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.repository < plexus.core
    [DEBUG]   Imported: org.apache.maven.wagon.resource < plexus.core
    [DEBUG]   Imported: org.codehaus.classworlds < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.* < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.classworlds < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.component < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.configuration < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.container < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.context < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.lifecycle < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.logging < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.personality < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.util.xml.Xpp3Dom < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParser < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParserException < plexus.core
    [DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlSerializer < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.* < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.artifact < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.collection < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.deployment < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.graph < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.impl < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.installation < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.internal.impl < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.metadata < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.repository < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.resolution < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.spi < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.transfer < plexus.core
    [DEBUG]   Imported: org.eclipse.aether.version < plexus.core
    [DEBUG]   Imported: org.slf4j.* < plexus.core
    [DEBUG]   Imported: org.slf4j.helpers.* < plexus.core
    [DEBUG]   Imported: org.slf4j.spi.* < plexus.core
    [DEBUG] Populating class realm maven.api
    [INFO] Error stacktraces are turned on.
    [DEBUG] Reading global settings from C:\apache-maven-3.3.9\bin\..\conf\settings.xml
    [DEBUG] Reading user settings from C:\Users\Paul\.m2\settings.xml
    [DEBUG] Reading global toolchains from C:\apache-maven-3.3.9\bin\..\conf\toolchains.xml
    [DEBUG] Reading user toolchains from C:\Users\Paul\.m2\toolchains.xml
    [DEBUG] Using local repository at C:\Users\Paul\.m2\repository
    [DEBUG] Using manager EnhancedLocalRepositoryManager with priority 10.0 for C:\Users\Paul\.m2\repository
    [INFO] Scanning for projects...
    [DEBUG] Extension realms for project org.apache.maven:standalone-pom:pom:1: (none)
    [DEBUG] Looking up lifecyle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
    [DEBUG] Resolving plugin prefix eclipse from [org.apache.maven.plugins, org.codehaus.mojo]
    [DEBUG] Could not find metadata org.apache.maven.plugins/maven-metadata.xml in local (C:\Users\Paul\.m2\repository)
    [DEBUG] Skipped remote request for org.apache.maven.plugins/maven-metadata.xml, locally cached metadata up-to-date.
    [DEBUG] Could not find metadata org.codehaus.mojo/maven-metadata.xml in local (C:\Users\Paul\.m2\repository)
    [DEBUG] Skipped remote request for org.codehaus.mojo/maven-metadata.xml, locally cached metadata up-to-date.
    [DEBUG] Resolved plugin prefix eclipse to org.apache.maven.plugins:maven-eclipse-plugin from repository central
    [DEBUG] Resolving plugin version for org.apache.maven.plugins:maven-eclipse-plugin
    [DEBUG] Could not find metadata org.apache.maven.plugins:maven-eclipse-plugin/maven-metadata.xml in local (C:\Users\Paul\.m2\repository)
    [DEBUG] Skipped remote request for org.apache.maven.plugins:maven-eclipse-plugin/maven-metadata.xml, locally cached metadata up-to-date.
    [DEBUG] Resolved plugin version for org.apache.maven.plugins:maven-eclipse-plugin to 2.10 from repository central (https://repo.maven.apache.org/maven2, default, releases)
    [DEBUG] Resolving plugin prefix eclipse from [org.apache.maven.plugins, org.codehaus.mojo]
    [DEBUG] Could not find metadata org.apache.maven.plugins/maven-metadata.xml in local (C:\Users\Paul\.m2\repository)
    [DEBUG] Skipped remote request for org.apache.maven.plugins/maven-metadata.xml, locally cached metadata up-to-date.
    [DEBUG] Could not find metadata org.codehaus.mojo/maven-metadata.xml in local (C:\Users\Paul\.m2\repository)
    [DEBUG] Skipped remote request for org.codehaus.mojo/maven-metadata.xml, locally cached metadata up-to-date.
    [DEBUG] Resolved plugin prefix eclipse to org.apache.maven.plugins:maven-eclipse-plugin from repository central
    [DEBUG] Resolving plugin version for org.apache.maven.plugins:maven-eclipse-plugin
    [DEBUG] Could not find metadata org.apache.maven.plugins:maven-eclipse-plugin/maven-metadata.xml in local (C:\Users\Paul\.m2\repository)
    [DEBUG] Skipped remote request for org.apache.maven.plugins:maven-eclipse-plugin/maven-metadata.xml, locally cached metadata up-to-date.
    [DEBUG] Resolved plugin version for org.apache.maven.plugins:maven-eclipse-plugin to 2.10 from repository central (https://repo.maven.apache.org/maven2, default, releases)
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 3.994 s
    [INFO] Finished at: 2015-12-29T11:20:07+01:00
    [INFO] Final Memory: 8M/101M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Could not find goal 'add-maven-repo' in plugin org.apache.maven.plugins:maven-eclipse-plugin:2.10 among available goals clean, configure-workspace, eclipse, help, install-plugins, myeclipse, myeclipse-clean, rad, rad-clean, remove-cache, resolve-workspace-dependencies, to-maven -> [Help 1]
    org.apache.maven.plugin.MojoNotFoundException: Could not find goal 'add-maven-repo' in plugin org.apache.maven.plugins:maven-eclipse-plugin:2.10 among available goals clean, configure-workspace, eclipse, help, install-plugins, myeclipse, myeclipse-clean, rad, rad-clean, remove-cache, resolve-workspace-dependencies, to-maven
            at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getMojoDescriptor(DefaultMavenPluginManager.java:290)
            at org.apache.maven.plugin.DefaultBuildPluginManager.getMojoDescriptor(DefaultBuildPluginManager.java:241)
            at org.apache.maven.lifecycle.internal.MojoDescriptorCreator.getMojoDescriptor(MojoDescriptorCreator.java:238)
            at org.apache.maven.lifecycle.internal.DefaultLifecycleTaskSegmentCalculator.calculateTaskSegments(DefaultLifecycleTaskSegmentCalculator.java:103)
            at org.apache.maven.lifecycle.internal.DefaultLifecycleTaskSegmentCalculator.calculateTaskSegments(DefaultLifecycleTaskSegmentCalculator.java:83)
            at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:89)
            at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
            at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
            at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
            at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)
            at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
            at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:606)
            at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
            at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
            at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
            at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
    [ERROR]
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoNotFoundException
    
    C:\Users\Paul>
    
    1. Use configure-workspace in place of add-maven-repo.  I encountered the same problem and found this link in a quick google search - http://maven.apache.org/plugins-archives/maven-eclipse-plugin-2.8/add-maven-repo-mojo.html

  51. Hi ,

    I have this requirement. Could someone please guide me - how to achive with existing plugins.

    TestNG,Robot Framework and Extent reports are getting generated in jenkins jobs.

    Scenario: 10 Jobs with each job having 5 Tests each

    • Pass Rate (PR)
      • In 1 week if each job will be triggered once daily, each one will have run 25 Tests (5 Tests/job x 5  days)
      • So, 10 Jobs x 25 Tests/job = 250 Tests triggered in 1 week
      • Pass Rate (PR) = Total # of Passed/Total  # of Tests
        • example: 235/250 (94%)
      • Note that, we are reporting Tests not Builds!
    • Average Run Time (ART)
      • This refers to the average time required to run the full test suite.
      • RTx = Average run time of each job [where x: 1,2,3,..10] computed as run time on each day divided by number of days [ (T1+T2+T3+T4+T5)/5 ]
      • ART = RT1 + RT2 + RT3 + ... + RT10
    • Total number of Tests triggered
      • Total number of unique tests run. In this example, this will be 10 Jobs x 5 Tests/Job so 50 unique tests.
    • Trend
      • Pass Rate
        • To monitor the state of our test scripts on a weekly basis. Mainly for stability or early detection of issues.
      • Average Run Time
        • To monitor if we can support the under 12 hours regression
      • Test Suite Size (Total number of Tests triggered)
        • To monitor if we are adding more tests to the automation suite

    Your quick reply will be greatly appreciated.

    Regards,
    LnT

  52. Hi,

    I have modified one of the plugin to suit to our needs. Say Plugin A. This plugin A has depedency on plugin B which too have been modified. Both plugin A and Plugin B have been forked and the changes are pushed to the forked repo on my github account. Now, when I build the plugin A, it is still referring to the old version of plugin B though the older version have been completely removed in the pom.xml and github details have been provided in the pom.xml of plugin A. Still, it is pointing to the older version of the plugin. Can you please help me in resolving this issue.

     

    Thanks.

  53. Hi,

    I try to follow the instruction, but after I would like to build, I got the following error log from the server refering some javadoc issue:

    1 error
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 15.025 s
    [INFO] Finished at: 2017-11-21T13:49:57+01:00
    [INFO] Final Memory: 130M/787M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default) on project jentest: An error has occurred in JavaDocs report generation:
    [ERROR] Exit code: 1 - java.lang.IllegalArgumentException
    [ERROR] at sun.net.www.ParseUtil.decode(ParseUtil.java:202)
    [ERROR] at sun.misc.URLClassPath$FileLoader.<init>(URLClassPath.java:1204)
    [ERROR] at sun.misc.URLClassPath$3.run(URLClassPath.java:525)
    [ERROR] at sun.misc.URLClassPath$3.run(URLClassPath.java:520)
    [ERROR] at java.security.AccessController.doPrivileged(Native Method)
    [ERROR] at sun.misc.URLClassPath.getLoader(URLClassPath.java:519)
    [ERROR] at sun.misc.URLClassPath.getLoader(URLClassPath.java:492)
    [ERROR] at sun.misc.URLClassPath.getNextLoader(URLClassPath.java:457)
    [ERROR] at sun.misc.URLClassPath.access$100(URLClassPath.java:64)
    [ERROR] at sun.misc.URLClassPath$1.next(URLClassPath.java:239)
    [ERROR] at sun.misc.URLClassPath$1.hasMoreElements(URLClassPath.java:250)
    [ERROR] at java.net.URLClassLoader$3$1.run(URLClassLoader.java:601)
    [ERROR] at java.net.URLClassLoader$3$1.run(URLClassLoader.java:599)
    [ERROR] at java.security.AccessController.doPrivileged(Native Method)
    [ERROR] at java.net.URLClassLoader$3.next(URLClassLoader.java:598)
    [ERROR] at java.net.URLClassLoader$3.hasMoreElements(URLClassLoader.java:623)
    [ERROR] at sun.misc.CompoundEnumeration.next(CompoundEnumeration.java:45)
    [ERROR] at sun.misc.CompoundEnumeration.hasMoreElements(CompoundEnumeration.java:54)
    [ERROR] at java.util.ServiceLoader$LazyIterator.hasNextService(ServiceLoader.java:354)
    [ERROR] at java.util.ServiceLoader$LazyIterator.hasNext(ServiceLoader.java:393)
    [ERROR] at java.util.ServiceLoader$1.hasNext(ServiceLoader.java:474)
    [ERROR] at javax.xml.parsers.FactoryFinder$1.run(FactoryFinder.java:293)
    [ERROR] at java.security.AccessController.doPrivileged(Native Method)
    [ERROR] at javax.xml.parsers.FactoryFinder.findServiceProvider(FactoryFinder.java:289)
    [ERROR] at javax.xml.parsers.FactoryFinder.find(FactoryFinder.java:267)
    [ERROR] at javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:127)
    [ERROR] at com.sun.tools.doclets.internal.toolkit.builders.LayoutParser.parseXML(LayoutParser.java:89)
    [ERROR] at com.sun.tools.doclets.internal.toolkit.builders.ClassBuilder.build(ClassBuilder.java:120)
    [ERROR] at com.sun.tools.doclets.formats.html.HtmlDoclet.generateClassFiles(HtmlDoclet.java:189)
    [ERROR] at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.generateClassFiles(AbstractDoclet.java:192)
    [ERROR] at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.startGeneration(AbstractDoclet.java:137)
    [ERROR] at com.sun.tools.doclets.internal.toolkit.AbstractDoclet.start(AbstractDoclet.java:82)
    [ERROR] at com.sun.tools.doclets.formats.html.HtmlDoclet.start(HtmlDoclet.java:80)
    [ERROR] at com.sun.tools.doclets.standard.Standard.start(Standard.java:39)
    [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    [ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    [ERROR] at java.lang.reflect.Method.invoke(Method.java:498)
    [ERROR] at com.sun.tools.javadoc.DocletInvoker.invoke(DocletInvoker.java:310)
    [ERROR] at com.sun.tools.javadoc.DocletInvoker.start(DocletInvoker.java:189)
    [ERROR] at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:366)
    [ERROR] at com.sun.tools.javadoc.Start.begin(Start.java:219)
    [ERROR] at com.sun.tools.javadoc.Start.begin(Start.java:205)
    [ERROR] at com.sun.tools.javadoc.Main.execute(Main.java:64)
    [ERROR] at com.sun.tools.javadoc.Main.main(Main.java:54)
    [ERROR] javadoc: error - java.lang.IllegalArgumentException
    [ERROR]
    [ERROR] Command line was: "C:\Program Files\Java\jdk1.8.0_111\jre\..\bin\javadoc.exe" -J-Dhttp.proxySet=true -J-Dhttp.proxyHost=proxy -J-Dhttp.proxyPort=8080 @options @packages
    [ERROR]
    [ERROR] Refer to the generated Javadoc files in 'C:\Users\I307292\workspacenew\jentest\target\site\apidocs' dir.
    [ERROR] -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Write a comment…