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?