Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8201261

Ability to override the dependency repositories used by gradle

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: openjfx11
    • Fix Version/s: openjfx11
    • Component/s: javafx
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      master

      Description

      In a continuing effort to eliminate the need for anything from the closed repo, we need to add the ability to override the dependency repositories used by gradle when doing an open build, so that a build can use a locally cached version of all the dependencies (e.g., to avoid build-time dependencies on external hosts for build systems behind a firewall).

      Currently this is handled by having a supplemental closed gradle file define a repository, and logic in build.gradle to exclude the public repositories as follows:

          if (!BUILD_CLOSED) {
              repositories {
                  mavenCentral()
                  ivy {
                      ...
                  }
              }
          }

      Instead we want to be able to set an alternate repository URL on the command line. Something like this:

      gradle -PJFX_DEPS_URL="http://some.host/some/path" ...

      So we would add something like this:

      if (JFX_DEPS_URL != "") {
          repositories {
              ivy {
                  url JFX_DEPS_URL
                  layout "pattern", {
                      artifact "[artifact]-[revision](-[classifier]).[ext]"
                      artifact "[artifact].[ext]"
                  }
              }
          }
      }

      And all of the existing places where we qualify repos with:

          if (!BUILD_CLOSED)

      would become:

          if (JFX_DEPS_URL == "")

        Attachments

          Activity

            People

            • Assignee:
              kcr Kevin Rushforth
              Reporter:
              kcr Kevin Rushforth
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: