Nigel,
It's more of an observation rather than anything. Since we inject using
persistence context into an active EJB context, the EE platform allows more
generic injection similar to what we are trying to achieve with messaging
context. I'm wondering how CDI will handle this type of injection.
John
On Mon, Feb 13, 2012 at 9:11 AM, Nigel Deakin <nigel.deakin_at_oracle.com>wrote:
> John,
>
>
> On 11/02/2012 15:39, John D. Ament wrote:
>
>> I've been thinking on this subject a bit. I think the issue is that for
>> JMS to work right with injection and
>> annotations, the annotations need to act like the annotations in JPA when
>> injection is supported (e.g.
>> @PersistenceContext).
>>
>
> Can you please elaborate on this? There are several aspects to
> PersistenceContext and I'd be interested in knowing what particular aspects
> you had in mind.
>
> You can use the @PersistenceContext annotation to inject a EntityManager:
>
> @PersistenceContext EntityManager em;
>
> Compare this with the current proposal to inject a MessagingContext:
>
> @Inject MessagingContext context;
>
> Were you thinking of replacing "@Inject" with something more specific?
>
> Or were you thinking of something else, like the ability to annotate
> methods?
>
> Nigel
>
>
>
> > I don't think CDI has this supported quite well yet. Pete, any comment
> on this?
>
>