I am currently working on an application that uses Spring's JMS Messaging (JMSTemplate). The application needs to send a message to a mainframe queue that is not able to decipher the "RFH" header that the JMSTemplate appends to the message. Is there a way to entirely remove all the header information progamatically so the mainframe can just get the raw contents of the message without the header?
Here is my code...
MQQueueConnectionFactory connectionFactory = new MQQueueConnectionFactory();
connectionFactory.setHostName( "127.0.0.1" );
connectionFactory.setPort( 1414 );
connectionFactory.setChannel( "S_LOCALHOST" );
connectionFactory.setQueueManager( "QM_LOCALHOST" );
connectionFactory.setTransportType( 1 );
UserCredentialsConnectionFactoryAdapter credentials = new UserCredentialsConnectionFactoryAdapter();
credentials.setUsername( "" );
credentials.setPassword( "" );
credentials.setTargetConnectionFactory( connectionFactory );
JmsTemplate jmsTemplate = new JmsTemplate( credentials );
jmsTemplate.setPubSubDomain( false );
jmsTemplate.setDeliveryMode( javax.jms.DeliveryMode.NON_PERSISTENT );
jmsTemplate.setExplicitQosEnabled( true );
jmsTemplate.setReceiveTimeout( 60000 );
jmsTemplate.convertAndSend( "MY.QUEUE", "cobol data" );
Here is what the message looks like in the Websphere MQ Explorer. How can I remove these values? Is it even possible with Spring JMS? Lemme know if you need any more info...