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

4.x Allow programmatic look-up of MetricRegistry via CDI without NPE #8210

Merged
merged 2 commits into from Jan 8, 2024

Conversation

tjquinno
Copy link
Member

@tjquinno tjquinno commented Jan 8, 2024

Description

Resolves #8209

The producer method failed to check that the injection point and its getAnnotated() return value were non-null before using them. Thus CDI.current().select(MetricRegistry.class).get() triggered an NPE.

(It turned out that the InjectionPoint passed is non-null but its getAnnotated() return value was null in this case.)

Documentation

Bug fix - no doc impact

Signed-off-by: Tim Quinn <tim.quinn@oracle.com>
@tjquinno tjquinno self-assigned this Jan 8, 2024
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Jan 8, 2024
@tjquinno tjquinno requested a review from spericas January 8, 2024 18:51
@tjquinno tjquinno merged commit 1899ca1 into helidon-io:main Jan 8, 2024
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4.x CDI.current().select(MetricRegistry.class).get() throws NPE
2 participants