I'm not an expert in CDI, but in the past those kind of resources where injected correctly only into EJB's - are you sure you can get this data without annotating the class with @Singleton or some other annotation that suites your logic?

The reason the servlet example works is because you can actually get injection in a servlet. You can't just inject dependencies in any POJO you want. Where injection isn't supported you will have to use the traditional JNDI lookup pattern.

The only other change I had to make was to include the destination in the messageProducer.send call.

You don't have to do it this way. Your call to javax.jms.Session.createProducer(Destination) should use the javax.jms.Destination you looked up in JNDI. You are using a variable named "queue" which I don't see defined. Also, you don't need to invoke javax.jms.Connection.start() as this only applies to consumers. For example:

In your last answer would this indicate that if I were to make my POJO a SLSB then I would have been able to use the same code that I origianlly had?

If yes is then one method perferred over the other? Lets say for performance reasons?

If you made your POJO an SLSB then you would be able to use injection because injection is valid for an SLSB whereas injection is not valid for a POJO. Injection requires a bit less application code than the normal JNDI look-up pattern, and for that reason it is generally preferred. However, changing your POJO into an SLSB may not be what you want to do (for whatever reason). Performance really isn't a factor when deciding whether or not to use injection. However, performance can definitly be a factor when deciding on a POJO vs. SLSB since SLSBs are pooled and can oftentimes provide a better QOS than POJOs. It all depends on how you're using this code.

The NameNotFoundException you are receiving is accurate. You don't have a JMS queue bound to "java:queue/admhcontrol". Anything bound in the "java:jboss/exported" namespace is exposed to remote clients - that's what this namespace is for. A remote client would look it up by using whatever comes after "java:jboss/exported". For example, a remote client would look-up this queue by using "jms/queue/admhcontrol". If you wanted to look it up locally using this entry you'd use "java:jboss/exported/jms/queue/admhcontrol".

If you want your queue bound to "java:queue/admhcontrol" then define it like this: