I was using M6 before and latter I tried to change the same code with RCI.May be would be the problem with jars m6 and RC1 together. After tht I created a fresh project and tried to run the same code with RCI jars alone and this ClassCastException disappeared but I have the below Exception (as taked b4)still when using jms outbound gateway
Code:
HTTP ERROR: 500
javax.jms.JMSException: Failed to build body from bytes. Reason: java.io.IOException: org.springframework.integration.message.GenericMessage
RequestURI=/admin/message.jsp
javax.el.ELException: javax.jms.JMSException: Failed to build body from bytes. Reason: java.io.IOException: org.springframework.integration.message.GenericMessage
I dont understand this exception cos I tried to check what class it returns and it gave me the below Class. Im using these two packages:
Code:
import org.springframework.integration.core.Message;
import org.springframework.integration.core.MessageChannel;
Code:
Message<String> message = MessageBuilder.withPayload(requestXml)
.setHeader(AbstractWebServiceOutboundGateway.SOAP_ACTION_PROPERTY_KEY, "http://mycompany.com/hr/schemas").build();
System.out.println(message.getClass());
Returned Class:
Code:
class org.springframework.integration.message.GenericMessage