no CDI request context in Kafka consumer #46153
Labels
area/arc
Issue related to ARC (dependency injection)
area/kafka
kind/enhancement
New feature or request
Description
I just received this report via the Hibernate issue tracker:
https://hibernate.atlassian.net/browse/HHH-19109
Apparently the CDI request context is not available from a Kafka consumer.
But a Kafka consumer is, I suppose, 100% analogous to a JMS
MessageListener
, and so it should be quite clear from the CDI spec that the intent is for such callbacks to have a request context.Bit in case there's any doubt: the intention of the CDI spec is that there is always an active context for the
@RequestScoped
scope type in any scope where application program logic is executing. The explicit list of scenarios in the Javadoc is a floor, not a ceiling.Implementation ideas
No response
The text was updated successfully, but these errors were encountered: