Skip to content

More javadoc for RootAction.isPrimary - #10767

Merged
krisstern merged 3 commits into
jenkinsci:masterfrom
jtnord:more-javadoc-for-rootAction.isPrimary
Jul 5, 2025
Merged

More javadoc for RootAction.isPrimary#10767
krisstern merged 3 commits into
jenkinsci:masterfrom
jtnord:more-javadoc-for-rootAction.isPrimary

Conversation

@jtnord

@jtnord jtnord commented Jun 23, 2025

Copy link
Copy Markdown
Member

Builds on the base commit from #10729 to address the comment from @janfaracik

Testing done

Confirmed text renders as expected.

Proposed changelog entries

  • N/A

Proposed changelog category

/label skip-changelog

Proposed upgrade guidelines

N/A

Submitter checklist

  • The Jira issue, if it exists, is well-described.
  • The changelog entries and upgrade guidelines are appropriate for the audience affected by the change (users or developers, depending on the change) and are in the imperative mood (see examples). Fill in the Proposed upgrade guidelines section only if there are breaking changes or changes that may require extra steps from users during upgrade.
  • There is automated testing or an explanation as to why this change has no tests.
  • New public classes, fields, and methods are annotated with @Restricted or have @since TODO Javadocs, as appropriate.
  • New deprecations are annotated with @Deprecated(since = "TODO") or @Deprecated(forRemoval = true, since = "TODO"), if applicable.
  • New or substantially changed JavaScript is not defined inline and does not call eval to ease future introduction of Content Security Policy (CSP) directives (see documentation).
  • For dependency updates, there are links to external changelogs and, if possible, full differentials.
  • For new APIs and extension points, there is a link to at least one consumer.

Desired reviewers

@mention

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

Maintainer checklist

  • There are at least two (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 is not blocking the change.
  • Changelog entries in the pull request title and/or Proposed changelog entries are accurate, human-readable, and in the imperative mood.
  • Proper changelog labels are set so that the changelog can be generated automatically.
  • If the change needs additional upgrade steps from users, the upgrade-guide-needed label is set and there is a Proposed upgrade guidelines section in the pull request title (see 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).

@jtnord jtnord added developer Changes which impact plugin developers skip-changelog Should not be shown in the changelog and removed developer Changes which impact plugin developers labels Jun 23, 2025

/**
* Identifies if the action as a primary action.
* Primary actions may be handled differently in the UI (for existence by always showing on the header rather than in an actions dropdown).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
* Primary actions may be handled differently in the UI (for existence by always showing on the header rather than in an actions dropdown).
* Primary actions may be handled differently in the UI (for example by always showing on the header rather than in an actions dropdown).

Comment thread core/src/main/java/hudson/model/RootAction.java Outdated
Comment thread core/src/main/java/hudson/model/RootAction.java Outdated
Comment thread core/src/main/java/hudson/model/RootAction.java Outdated
Comment thread core/src/main/java/jenkins/views/Header.java Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Please take a moment and address the merge conflicts of your pull request. Thanks!

@github-actions github-actions Bot added the unresolved-merge-conflict There is a merge conflict with the target branch. label Jun 23, 2025
@jtnord jtnord closed this Jun 24, 2025
@jtnord
jtnord force-pushed the more-javadoc-for-rootAction.isPrimary branch from c7faddc to 39e85a0 Compare June 24, 2025 12:18
@jtnord jtnord reopened this Jun 24, 2025
@jtnord
jtnord marked this pull request as ready for review June 24, 2025 12:20
@github-actions github-actions Bot removed the unresolved-merge-conflict There is a merge conflict with the target branch. label Jun 24, 2025
@jtnord
jtnord requested review from daniel-beck and janfaracik June 24, 2025 12:20
* As concrete example, an action that provides a Help action with a submenu containing various different links, would be a prime candidate for this to return {@code true}.
* If your action has the possibility of a {@link #getBadge() badge} then this is another indicator that the action should return {@code true} (or otherwise restructured).
* @return {@code true} if and only if this action should be considered primary.
* @since 2.516

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

upstream change has been merged after 2.515 and before 2.516 so it would be this.
Changed here to avoid leaving a known TODO in the code.

Comment thread core/src/main/java/hudson/model/RootAction.java Outdated
@github-actions github-actions Bot added the unresolved-merge-conflict There is a merge conflict with the target branch. label Jun 26, 2025
@github-actions

Copy link
Copy Markdown
Contributor

Please take a moment and address the merge conflicts of your pull request. Thanks!

A1exKH
A1exKH previously requested changes Jun 27, 2025

@A1exKH A1exKH left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

@jtnord please resolve conflicts for this PR before review.

@jtnord
jtnord requested a review from A1exKH June 27, 2025 10:53
@github-actions github-actions Bot removed the unresolved-merge-conflict There is a merge conflict with the target branch. label Jun 27, 2025

@A1exKH A1exKH left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM.

@jtnord
jtnord requested a review from a team July 4, 2025 09:35

@MarkEWaite MarkEWaite left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks!

@MarkEWaite

Copy link
Copy Markdown
Contributor

This PR is now ready for merge. We will merge it after approximately 24 hours if there is no negative feedback.

/label ready-for-merge

@comment-ops-bot comment-ops-bot Bot added the ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback label Jul 4, 2025
@MarkEWaite MarkEWaite changed the title More javadoc for root action.is primary More javadoc for RootAction.isPrimary Jul 4, 2025
@krisstern
krisstern merged commit be395d4 into jenkinsci:master Jul 5, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback skip-changelog Should not be shown in the changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants