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

DefaultUpdateSiteID option from JENKINS-34674 does not really switch default

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved (View Workflow)
    • Major
    • Resolution: Fixed
    • core
    • None
    • jenkins-2.5

    Description

      Implementation of JENKINS-34674 was not completely correct.
      DEFAULT_SITE_ID has too wide effect.

      Expected behavior:

      • Jenkins uses another update site as a default one

      Actual behavior:

      • Jenkins renames the default update site to DEFAULT_SITE_ID
      • Jenkins still uses this update site as a default, because it's the first in the list

      Workaround: When adding an custom UpdateSite in the code, delete the default site from the list, rename default site to the original ID, then add it back.

      Attachments

        Issue Links

          Activity

            oleg_nenashev Oleg Nenashev added a comment -

            Description of my case, where I get into the issue:
            1) I have 2 update centers. "my-uc" and "default". Default points to Jenkins OSS, "my-uc" - to my site. "my-uc" is added by the code, it does not modify UpdateCenter settings
            2) In System properties I set DEFAULT_UC_ID to "my-uc"
            3) When Jenkins initializes the instance, it takes the default settings from update center and creates it as "my-uc"
            4) When my code adds the real "my-uc" site, there is a conflict

            oleg_nenashev Oleg Nenashev added a comment - Description of my case, where I get into the issue: 1) I have 2 update centers. "my-uc" and "default". Default points to Jenkins OSS, "my-uc" - to my site. "my-uc" is added by the code, it does not modify UpdateCenter settings 2) In System properties I set DEFAULT_UC_ID to "my-uc" 3) When Jenkins initializes the instance, it takes the default settings from update center and creates it as "my-uc" 4) When my code adds the real "my-uc" site, there is a conflict

            Code changed in jenkins
            User: Valentina Armenise
            Path:
            core/src/main/java/hudson/model/UpdateCenter.java
            http://jenkins-ci.org/commit/jenkins/1e746f6ee0d31fad5efece6d829d3deb47a8a484
            Log:
            [FIXED JENKINS-34883] the legacy default update site can be different from the one specified by ID_DEFAULT

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Valentina Armenise Path: core/src/main/java/hudson/model/UpdateCenter.java http://jenkins-ci.org/commit/jenkins/1e746f6ee0d31fad5efece6d829d3deb47a8a484 Log: [FIXED JENKINS-34883] the legacy default update site can be different from the one specified by ID_DEFAULT

            Code changed in jenkins
            User: Valentina Armenise
            Path:
            core/src/main/java/hudson/model/UpdateCenter.java
            core/src/main/java/hudson/model/UpdateSite.java
            http://jenkins-ci.org/commit/jenkins/1e80c681dc21eae17e81834177827e19b10c2457
            Log:
            [FIXED JENKINS-34883] use an ovverridable createDefaultUpdateSite method

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Valentina Armenise Path: core/src/main/java/hudson/model/UpdateCenter.java core/src/main/java/hudson/model/UpdateSite.java http://jenkins-ci.org/commit/jenkins/1e80c681dc21eae17e81834177827e19b10c2457 Log: [FIXED JENKINS-34883] use an ovverridable createDefaultUpdateSite method

            Code changed in jenkins
            User: Valentina Armenise
            Path:
            core/src/main/java/hudson/model/UpdateCenter.java
            http://jenkins-ci.org/commit/jenkins/fd7e6c69d1834df753b9126f3c909b50e18bfe5f
            Log:
            [FIXED JENKINS-34883] make method protected

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Valentina Armenise Path: core/src/main/java/hudson/model/UpdateCenter.java http://jenkins-ci.org/commit/jenkins/fd7e6c69d1834df753b9126f3c909b50e18bfe5f Log: [FIXED JENKINS-34883] make method protected

            Code changed in jenkins
            User: valentina
            Path:
            core/src/main/java/hudson/model/UpdateCenter.java
            core/src/main/java/hudson/model/UpdateSite.java
            http://jenkins-ci.org/commit/jenkins/02e4bc51b8f662c3b8f13cf0c4408b1aab48e5a3
            Log:
            Merge pull request #2363 from varmenise/JENKINS-34883

            [FIXED JENKINS-34883] the legacy default update site can be different from the one specified by ID_DEFAULT

            Compare: https://github.com/jenkinsci/jenkins/compare/b0fd310ab61d...02e4bc51b8f6

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: valentina Path: core/src/main/java/hudson/model/UpdateCenter.java core/src/main/java/hudson/model/UpdateSite.java http://jenkins-ci.org/commit/jenkins/02e4bc51b8f662c3b8f13cf0c4408b1aab48e5a3 Log: Merge pull request #2363 from varmenise/ JENKINS-34883 [FIXED JENKINS-34883] the legacy default update site can be different from the one specified by ID_DEFAULT Compare: https://github.com/jenkinsci/jenkins/compare/b0fd310ab61d...02e4bc51b8f6

            People

              varmenise valentina armenise
              oleg_nenashev Oleg Nenashev
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: