com.sun.ejb.containers,com.sun.ejb.spi.io
This allowed us to have a ManagedBean in the bundle.
For example - want to have a @Singleton class for some processing.
@Singleton
public class TestSingleton {
public String testMySingleton() {
return "This is a test from my singleton!";
}
}
(this would be a javax.annotation.ManagedBean, not a Faces ManagedBean):
@ManagedBean
public class SingBean {
@EJB
private TestSingleton testSingleton;
and for testing purposes - within the MDB:
@MessageDriven(mappedName = "jms/MyQueue", activationConfig = {
@ActivationConfigProperty(propertyName = "acknowledgeMode", propertyValue = "Auto-acknowledge"),
@ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
})
public class ExtIncMDB {
@Resource
SingBean myBean;

No comments:
Post a Comment