Skip to content

Add missing @Inject annotations to JWTAuthContextInfoProvider fields#914

Open
lrasku wants to merge 1 commit into
smallrye:mainfrom
lrasku:bugfix/missing-inject-annotations
Open

Add missing @Inject annotations to JWTAuthContextInfoProvider fields#914
lrasku wants to merge 1 commit into
smallrye:mainfrom
lrasku:bugfix/missing-inject-annotations

Conversation

@lrasku

@lrasku lrasku commented Jul 6, 2026

Copy link
Copy Markdown

Absent these, these fields will not get populated from the configuration in a CDI environment.

Absent these, these fields will not get populated from the configuration
in a CDI environment.
@sberyozkin

Copy link
Copy Markdown
Contributor

@lrasku That is usually managed by the integrating container like Quarkus or Wildfly

@lrasku

lrasku commented Jul 14, 2026

Copy link
Copy Markdown
Author

I'm using smallrye-jwt in a Jetty+Weld configuration. But is there something special about these fields that they should not be populated via standard CDI injection? This class has many other @ConfigProperty(name = "smallrye.jwt.XXXX") fields, but only the ones in this pull request lacked the @Inject annotation.

@Ladicek

Ladicek commented Jul 14, 2026

Copy link
Copy Markdown
Member

An injection point without @Inject but with a qualifier is automatically recognized by ArC (see https://quarkus.io/guides/cdi-reference#qualified-injected-fields). It is very much non-standard behavior and I'd recommend to not rely on this outside Quarkus.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants