Configure Message Selectors with Message-Driven Beans
32.1.3. Using Message Selectors with Message-Driven Beans It is also possible to use MDBs with message selectors. To do this simple define your message selector as follows: @MessageDriven(name = "MDBMessageSelectorExample", activationConfig = { @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue"), @ActivationConfigProperty(propertyName = "destination", propertyValue = "queue/testQueue"), @ActivationConfigProperty(propertyName = "messageSelector", propertyValue = "color = 'RED'") }) @TransactionManagement(value= TransactionManagementType.CONTAINER) @TransactionAttribute(value= TransactionAttributeType.REQUIRED) @ResourceAdapter("hornetq-ra.rar") public class MDBMessageSelectorExample implements MessageListener { public void onMessage(Message message).... }