Spring JMS Oracle AQ - Specifying Dequeue Options

800 Views Asked by At

I am using Spring JMS for oracle AQ. How can I specifiy Dequeue options? I want to specify consumer name and dequeue_mode options.

1

There are 1 best solutions below

0
On

Old question but here is an XML configuration example. The consumer name property is called "messageListener". I'm not sure what dequeue_mode is... I'd recommend looking at the documentation for the AbstractPollingMessageListenerContainer for all of the available properties.

<bean id="myBeanId" class="org.springframework.jms.listener.DefaultMessageListenerContainer">
    <property name="connectionFactory" ref="myConnectionFactory"/>
    <property name="transactionManager" ref="myTransactionManager"/>
    <property name="destinationName" value="myDestinationName"/>
    <property name="messageListener" ref="myConsumer"/>
    <property name="concurrency" value="1-50"/>
    <property name="receiveTimeout" value="5000"/>
    <property name="idleTaskExecutionLimit" value="10"/>
    <property name="idleConsumerLimit" value="5"/>
    <property name="messageSelector" value="JMSType = 'mySelectorIfNeeded'"/>
    <property name="cacheLevelName" value="CACHE_CONSUMER"/>
    <property name="sessionTransacted" value="true"/>
</bean>