Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-64746] public API hudson.model.UpdateCenter.HudsonUpgradeJob constructor signature change #5216

Merged
merged 6 commits into from
Feb 1, 2021

Conversation

escoem
Copy link
Contributor

@escoem escoem commented Jan 29, 2021

See JENKINS-64746.

The breaking change was introduced by #4848

Proposed changelog entries

  • Restore, as deprecated, the old constructor based on acegisecurity Authentication parameter in order to keep backward compatibility.

Proposed upgrade guidelines

N/A

Submitter checklist

  • (If applicable) Jira issue is well described
  • Changelog entries and upgrade guidelines are appropriate for the audience affected by the change (users or developer, depending on the change). Examples
    • Fill-in the Proposed changelog entries section only if there are breaking changes or other changes which may require extra steps from users during the upgrade
  • Appropriate autotests or explanation to why this change has no tests
  • For dependency updates: links to external changelogs and, if possible, full diffs

Desired reviewers

@jglick

Maintainer checklist

Before the changes are marked as ready-for-merge:

  • There are at least 2 approvals for the pull request and no outstanding requests for change
  • Conversations in the pull request are over OR it is explicit that a reviewer does not block the change
  • Changelog entries in the PR title and/or Proposed changelog entries are correct
  • Proper changelog labels are set so that the changelog can be generated automatically
  • If the change needs additional upgrade steps from users, upgrade-guide-needed label is set and there is a Proposed upgrade guidelines section in the PR title. (example)
  • If it would make sense to backport the change to LTS, a Jira issue must exist, be a Bug or Improvement, and be labeled as lts-candidate to be considered (see query).

@oleg-nenashev oleg-nenashev added the bug For changelog: Minor bug. Will be listed after features label Jan 29, 2021
Copy link
Member

@oleg-nenashev oleg-nenashev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@timja timja requested a review from jglick January 29, 2021 14:01
@jtnord jtnord added the ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback label Jan 29, 2021
@@ -2111,6 +2111,15 @@ public InstallationJob(Plugin plugin, UpdateSite site, Authentication auth) {
this(plugin,site,auth,false);
}

/**
* @deprecated use {@code InstallationJob(Plugin, UpdateSite, Authentication, boolean)}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* @deprecated use {@code InstallationJob(Plugin, UpdateSite, Authentication, boolean)}
* @deprecated use {@link #InstallationJob(Plugin, UpdateSite, Authentication, boolean)}

@@ -2111,6 +2111,15 @@ public InstallationJob(Plugin plugin, UpdateSite site, Authentication auth) {
this(plugin,site,auth,false);
}

/**
* @deprecated use {@code InstallationJob(Plugin, UpdateSite, Authentication, boolean)}
* @see #InstallationJob(Plugin, UpdateSite, Authentication, boolean)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* @see #InstallationJob(Plugin, UpdateSite, Authentication, boolean)

Comment on lines 2339 to 2340
* @deprecated use {@code PluginDowngradeJob(Plugin, UpdateSite, Authentication)}
* @see #PluginDowngradeJob(Plugin, UpdateSite, Authentication)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

Comment on lines 2434 to 2435
* @deprecated use {@code HudsonUpgradeJob(UpdateSite site, Authentication auth)}
* @see #HudsonUpgradeJob(UpdateSite, Authentication)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

Comment on lines 2478 to 2479
* @deprecated use {@code HudsonDowngradeJob(UpdateSite site, Authentication auth)}
* @see #HudsonDowngradeJob(UpdateSite, Authentication)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

escoem and others added 2 commits January 29, 2021 17:09
Co-authored-by: Jesse Glick <jglick@cloudbees.com>
@oleg-nenashev
Copy link
Member

We may merge it in 24 hours if there is no negative feedback. Please see the merge process documentation for more information about the merge process

public InstallationJob(Plugin plugin, UpdateSite site, org.acegisecurity.Authentication auth, boolean dynamicLoad) {
this(plugin, site, auth.toSpring(), dynamicLoad);
}

public InstallationJob(Plugin plugin, UpdateSite site, Authentication auth, boolean dynamicLoad) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would also be polite to add @since 2.266 for the Spring overloads.

@@ -2410,6 +2427,15 @@ public String toString() {
* Represents the state of the upgrade activity of Jenkins core.
*/
public final class HudsonUpgradeJob extends DownloadJob {

/**
* @deprecated use {@link HudsonUpgradeJob(UpdateSite site, Authentication auth)}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* @deprecated use {@link HudsonUpgradeJob(UpdateSite site, Authentication auth)}
* @deprecated use {@link HudsonUpgradeJob(UpdateSite, Authentication)}

How is this not a build failure? Hmm…

@@ -2444,6 +2470,15 @@ protected void replace(File dst, File src) throws IOException {
}

public final class HudsonDowngradeJob extends DownloadJob {

/**
* @deprecated use {@link HudsonDowngradeJob(UpdateSite site, Authentication auth)}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* @deprecated use {@link HudsonDowngradeJob(UpdateSite site, Authentication auth)}
* @deprecated use {@link HudsonDowngradeJob(UpdateSite, Authentication)}

@@ -30,6 +30,7 @@
import java.util.Map;
import java.util.UUID;

import hudson.security.ACL;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import hudson.security.ACL;

@timja timja merged commit 2c1e839 into jenkinsci:master Feb 1, 2021
timja pushed a commit to timja/jenkins that referenced this pull request Feb 17, 2021
… constructor signature change (jenkinsci#5216)

Co-authored-by: Jesse Glick <jglick@cloudbees.com>
(cherry picked from commit 2c1e839)
timja pushed a commit to timja/jenkins that referenced this pull request Feb 17, 2021
… constructor signature change (jenkinsci#5216)

Co-authored-by: Jesse Glick <jglick@cloudbees.com>
(cherry picked from commit 2c1e839)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug For changelog: Minor bug. Will be listed after features ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback
Projects
None yet
6 participants