views:

592

answers:

3

Hello everyone,

I am using spring 2.5.6 and spring-integration 1.0.3 and MQ client 6.0.2.2

I have had to add a message selector to my message-driven-channel-adapter, but now I am getting the following error:

MQJMS2008: failed to open MQ queue ; nested exception is com.ibm.mq.MQException: MQJE001: Completion Code 2, Reason 2085

It works when I used ActiveMQ as a test harness.

My configuration:

<jms:message-driven-channel-adapter 
    id="jmsIn" 
    channel="inboundMessage" 
    container="myContainer"/>

<bean id="myContainer" 
    class="org.springframework.jms.listener.DefaultMessageListenerContainer">
    <property name="connectionFactory" ref="connectionFactory"/>
    <property name="destinationName" value="myQueue"/>
    <property name="messageSelector" ref="messageSelector"/>
    <property name="transactionManager" ref="txManager"/>
</bean>

If I revert to my previous configuration it's all good (except I don't have a message selector!)

<jms:message-driven-channel-adapter 
    id="jmsIn" 
    destination="tradeQueue" 
    channel="inboundMessage" 
    transaction-manager="txManager"/>

Help urgently required and very much appreciated.

Paul

A: 

"Help urgently required" hehe

Stay at the office all night, sit tight and wait! We'll do the best that we can!

anonymous
You should post this as comment before it gets downvoted (it's not an answer, is it?).
Pascal Thivent
Down-voted. Gratuitously flippant.
Paul McKenzie
As I'm anonymous, I can't comment, feel free to down-vote it, I don't mind at all.
anonymous
+1  A: 

Ah!

Where I had

<property name="destinationName" value="myQueue"/>

I should have had

<property name="destinationName" ref="myQueue"/>

Skaffman was right, the queue didn't actually exist.

P

Paul McKenzie
A: 

how did you get the MQ message in spring integration ?

as a jms message or spring integration message ?

Mohan
SpringIntegration channel adapter to read the JMS message and turn it into a Spring Integration message.
Paul McKenzie