Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-7420

Property interpolation in repository <url> no longer works

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Not A Bug
    • 3.0-alpha-1
    • None
    • Profiles, Settings
    • None

    Description

      We're using the Jenkins "Maven Repository Server" Plugin that provides automatic upstream repository configuration for a downstream build job.
      The plugin basically hosts a repository with the artifacts of the upstream job for consumption by a downstream job.

      It configures the upstream repository by setting a system property Jenkins.Repository which is configured in a <repository> section e.g. in settings.xml or pom.xml:

      <repository>
               <id>upstream</id>
               <url>${env.Jenkins.Repository}</url>
               <releases>
                   <enabled>true</enabled>
               </releases>
               <snapshots>
                  <enabled>true</enabled>
               </snapshots>
            </repository>
      

      With Maven 4.0.0-alpha1 (69d6c6d5a2886bd76fa9d0e922677d4654d1d90b). this does not work anymore:

      [ERROR]   The project de.gebit.test:3.2.0-SNAPSHOT (/home/my/projects/test/pom.xml) has 2 errors
      [ERROR]     'profiles.profile[jenkins-maven-upstream].repositories.repository.[jenkins].url' contains an expression but should be a constant. @ de.gebit.test-parent:3.1.1
      [ERROR]     'profiles.profile[jenkins-maven-upstream].pluginRepositories.pluginRepository.[jenkins].url' contains an expression but should be a constant. @ de.gebit.test-parent:3.1.1
      

      It seems that interpolation of the url is no longer possible.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              carsten.pfeiffer Carsten Pfeiffer
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: