Uploaded image for project: 'Spring Web Services'
  1. Spring Web Services
  2. SWS-258

getting error when trying to use IBM MQ JMS implementation as transport.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.5 M1
    • Fix Version/s: 1.5 M2
    • Component/s: Core
    • Labels:
      None
    • Environment:
      Windows XP, JDK 1.5, Eclipse 3.3, IBM MQ 6.0.0.0 - j000-L050519.1, SAAJ 1.2

      Description

      I already have a working version of Spring 1.0 with JMS/MQ as transport. We extended 1.0 to add that support. Since 1.5 has built-in support, I am trying to use 1.5 M1. I am getting following error when I try to send a message. Including configuration file except and also exception trace.

      This framework has been excellent help so far. It is well written. Thanks for developing this.

      I will also be doing investigation regarding this issue.

      Configuration :

      <bean id="jndiTemplate" class="org.springframework.jndi.JndiTemplate">
      <property name="environment">
      <props>
      <prop key="java.naming.factory.initial">com.ibm.mq.jms.context.WMQInitialContextFactory</prop>
      <prop key="java.naming.provider.url">QM_wwhq458m</prop>
      </props>
      </property>
      </bean>

      <!-- JMS Queue Connection Factory -->
      <bean id="internalJmsQueueConnectionFactory"
      class="org.springframework.jndi.JndiObjectFactoryBean">
      <property name="jndiTemplate">
      <ref bean="jndiTemplate"/>
      </property>
      <property name="jndiName">
      <value>QM_wwhq458m</value>
      </property>
      </bean>

      <!-- Spring JMS Queue Connection Factory -->
      <bean id="jmsQueueConnectionFactory"
      class="org.springframework.jms.connection.SingleConnectionFactory102">
      <property name="targetConnectionFactory">
      <ref bean="internalJmsQueueConnectionFactory"/>
      </property>
      <property name="pubSubDomain">
      <value>false</value>
      </property>
      </bean>

      <!-- JMS Destination Resolver -->
      <bean id="jmsDestinationResolver"
      class="org.springframework.jms.support.destination.JndiDestinationResolver">
      <property name="jndiTemplate">
      <ref bean="jndiTemplate"/>
      </property>
      <property name="cache">
      <value>true</value>
      </property>
      </bean>

      <bean id="JMSMQSender" class="org.springframework.ws.transport.jms.JmsMessageSender">
      <property name="connectionFactory" ref="jmsQueueConnectionFactory"/>
      </bean>
      <bean id="webServiceTemplate" class="org.springframework.ws.client.core.WebServiceTemplate">
      <property name="messageSenders">
      <list>
      <ref local="JMSMQSender" />
      <ref local="HttpUrlConnectionMessageSender" />
      </list>
      </property>
      <property name="defaultUri" value="jms:RequestQueue?deliveryMode=NON_PERSISTENT"/>
      <property name="marshaller">
      <ref local="RequestPayloadMarshaller" />
      </property>
      <property name="unmarshaller">
      <ref local="ResponsePayloadUnmarshaller" />
      </property>
      </bean>

      Exception Trace :

      Caused by: org.springframework.ws.client.WebServiceTransportException: Could not use transport: Could not set property: MQJMS1058: Invalid message property name: Content-Type; nested exception is org.springframework.ws.transport.jms.JmsTransportException: Could not set property: MQJMS1058: Invalid message property name: Content-Type
      at org.springframework.ws.client.core.WebServiceTemplate.sendAndReceive(WebServiceTemplate.java:430)
      at org.springframework.ws.client.core.WebServiceTemplate.doSendAndReceive(WebServiceTemplate.java:360)
      at org.springframework.ws.client.core.WebServiceTemplate.sendSourceAndReceiveToResult(WebServiceTemplate.java:306)
      at com.ual.caribou.transport.JMSTransportNew.invoke(JMSTransportNew.java:70)
      at com.ual.caribou.core.CaribouDispatchImpl.invoke(CaribouDispatchImpl.java:118)
      ... 20 more
      Caused by: org.springframework.ws.transport.jms.JmsTransportException: Could not set property: MQJMS1058: Invalid message property name: Content-Type
      at org.springframework.ws.transport.jms.JmsSenderConnection.addRequestHeader(JmsSenderConnection.java:152)
      at org.springframework.ws.transport.AbstractSenderConnection$RequestTransportOutputStream.addHeader(AbstractSenderConnection.java:108)
      at org.springframework.ws.soap.saaj.Saaj12Implementation.writeTo(Saaj12Implementation.java:247)
      at org.springframework.ws.soap.saaj.SaajSoapMessage.writeTo(SaajSoapMessage.java:118)
      at org.springframework.ws.transport.AbstractWebServiceConnection.send(AbstractWebServiceConnection.java:36)
      at org.springframework.ws.client.core.WebServiceTemplate.sendRequest(WebServiceTemplate.java:550)
      at org.springframework.ws.client.core.WebServiceTemplate.sendAndReceive(WebServiceTemplate.java:408)
      ... 24 more
      Caused by: javax.jms.MessageFormatException: MQJMS1058: Invalid message property name: Content-Type
      at com.ibm.jms.JMSMessage.newMessageFormatException(JMSMessage.java:4674)
      at com.ibm.jms.JMSMessage.setStringProperty(JMSMessage.java:5658)
      at org.springframework.ws.transport.jms.JmsSenderConnection.addRequestHeader(JmsSenderConnection.java:149)
      ... 30 more

        Attachments

          Activity

            People

            • Assignee:
              arjen.poutsma Arjen Poutsma
              Reporter:
              thapasya1 BN
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: