Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-21743

Enable/Implement CLI parameter submission for Maven Metadata Plugin

    XMLWordPrintable

Details

    Description

      CLI parameter submission is not support for this plugin. When invoking jenkins-cli build on a specific job that use "maven metadata plugin":
      java -jar jenkins-cli.jar -s http://myjenkins.test.com/ build refresh-setup2-5-install-version -p STATIC_ROLLOUT=1.0.26

      I get the following error:
      CLI parameter submission is not supported for the class eu.markov.jenkins.plugin.mvnmeta.MavenMetadataParameterDefinition type. Please file a bug report for this

      Here is a sample of the config.xml (Changed some namespace for anonymous reason):
      <eu.markov.jenkins.plugin.mvnmeta.MavenMetadataParameterDefinition plugin="maven-metadata-plugin@1.0.0">
      <name>STATIC_ROLLOUT</name>
      <description></description>
      <repoBaseUrl>http://nexus.xxxxx.com/content/repositories/xxxxx-repository</repoBaseUrl>
      <groupId>com.xxxxx.xxxxx.operating</groupId>
      <artifactId>xxxxx-xxxxx-rollout</artifactId>
      <packaging></packaging>
      <defaultValue></defaultValue>
      <versionFilter></versionFilter>
      <sortOrder>DESC</sortOrder>
      <maxVersions>10</maxVersions>
      </eu.markov.jenkins.plugin.mvnmeta.MavenMetadataParameterDefinition>

      This feature would be a huge progress for us... Is this plugin still maintained. Thanks for your help/feedback.

      Attachments

        Activity

          gesh Gesh Markov added a comment -

          I am not actively maintaining the plugin as I don't have the time for it.

          I would be happy to review a pull request and release another version if you want to look into how to enable this.

          gesh Gesh Markov added a comment - I am not actively maintaining the plugin as I don't have the time for it. I would be happy to review a pull request and release another version if you want to look into how to enable this.

          Hi Gesh,
          Pierre asked me to implement this feature.

          This is your repository, right? https://github.com/jenkinsci/maven-metadata-plugin
          I don't have experience in jenkins api yet.
          in order to get on track quickly, do you have a clue of what is missing?

          on a quick look, it seems that I just need to add a createValue(CLICommand, String) in MavenMetadataParameterDefinition.java.

          is that correct?

          https://github.com/jenkinsci/maven-metadata-plugin/blob/master/src/main/lombok/eu/markov/jenkins/plugin/mvnmeta/MavenMetadataParameterDefinition.java?source=cc

          http://javadoc.jenkins-ci.org/hudson/model/ParameterDefinition.html#createValue(hudson.cli.CLICommand, java.lang.String)

          dportabella David Portabella added a comment - Hi Gesh, Pierre asked me to implement this feature. This is your repository, right? https://github.com/jenkinsci/maven-metadata-plugin I don't have experience in jenkins api yet. in order to get on track quickly, do you have a clue of what is missing? on a quick look, it seems that I just need to add a createValue(CLICommand, String) in MavenMetadataParameterDefinition.java. is that correct? https://github.com/jenkinsci/maven-metadata-plugin/blob/master/src/main/lombok/eu/markov/jenkins/plugin/mvnmeta/MavenMetadataParameterDefinition.java?source=cc http://javadoc.jenkins-ci.org/hudson/model/ParameterDefinition.html#createValue(hudson.cli.CLICommand , java.lang.String)

          Hi,
          I've implemented the feature and it seems to work.

          I've sent you a push request:
          https://github.com/jenkinsci/maven-metadata-plugin/pull/4

          dportabella David Portabella added a comment - Hi, I've implemented the feature and it seems to work. I've sent you a push request: https://github.com/jenkinsci/maven-metadata-plugin/pull/4

          Awesome David! I'll test it tomorrow morning...

          zophar Pierre Hanselmann added a comment - Awesome David! I'll test it tomorrow morning...
          gesh Gesh Markov added a comment -

          Hey David,

          Thanks for taking the time to do this. The change looks good to me, so I will merge it in today and release the version 1.1.1 of the plugin.

          I'll resolve this bug when the new version is out.

          Cheers,
          Gesh

          gesh Gesh Markov added a comment - Hey David, Thanks for taking the time to do this. The change looks good to me, so I will merge it in today and release the version 1.1.1 of the plugin. I'll resolve this bug when the new version is out. Cheers, Gesh
          gesh Gesh Markov added a comment -

          The new version is out.

          It might take a couple of hours before you see that version via the built-in jenkins plugin management.

          Pierre, please close this bug if that versions really fixes your problem.

          gesh Gesh Markov added a comment - The new version is out. It might take a couple of hours before you see that version via the built-in jenkins plugin management. Pierre, please close this bug if that versions really fixes your problem.

          People

            gesh Gesh Markov
            zophar Pierre Hanselmann
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: