-
-
Notifications
You must be signed in to change notification settings - Fork 9k
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
Add ExtensionList.lookupFirst
convenience method.
#8735
Add ExtensionList.lookupFirst
convenience method.
#8735
Conversation
When introducing an extension point that is meant to allow overriding a default behaviour with another implementation, generally the caller only cares about looking up only one implementation, the one with the highest ordinal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple of Javadoc nits, but otherwise looks useful. Did you search for other possible usages in core?
Co-authored-by: Jesse Glick <[email protected]>
Surprisingly, I didn't find other usages in core. I think |
jenkins/core/src/main/java/hudson/model/Run.java Lines 1127 to 1135 in a23a8e5
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/label ready-for-merge
This PR is now ready for merge, after ~24 hours, we will merge it if there's no negative feedback.
Thanks!
When introducing an extension point that is meant to allow overriding a default behaviour with another implementation, generally the caller only cares about looking up only one implementation, the one with the highest ordinal.
See JENKINS-XXXXX.
Testing done
Proposed changelog entries
ExtensionList.lookupFirst
allows to retrieve the first implementation of an extension pointProposed upgrade guidelines
N/A
Submitter checklist
Desired reviewers
@mention
Before the changes are marked as
ready-for-merge
:Maintainer checklist