为什么我们只能在 EJB 中的消息驱动 bean 中设置单一目标类型?
@MessageDriven(activationConfig = {
@ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue"),
@ActivationConfigProperty(propertyName = "destination", propertyValue = "FileProcess"),
@ActivationConfigProperty(propertyName = "transactionTimeout", propertyValue = "3600"),
@ActivationConfigProperty(propertyName = "maxSession", propertyValue = "100") })
@TransactionManagement(value = TransactionManagementType.CONTAINER)
public class FileMDB implements MessageListener {
//.....
}
我想为单个 MSD 添加多个目标类型,我可以在 MDB 类中添加多个队列名称或目标类型吗?