Announcement Announcement Module
No announcement yet.
Question about DomResultFactory Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Question about DomResultFactory

    Hi, Im trying to transform the message payload to XML, Im able to transform it using <marshalling-transformer id="marshaller" marshaller="myMarshaller" result-factory="StringResult"/> but when I use result-factory="DOMResult" it always fails with error:

    Caused by: java.lang.IllegalArgumentException: DOMResult does not contain Node

    Im seeing that org.springframework.integration.xml.result.DomResu ltFactory always returns a new DomResult object but calling its default constructor

    public Result getNewResult(Message<?> message) {
    return new DOMResult();

    and when marshalling the OXM AbstractMarshaller class calls the following method and the exception is thrown.

    protected void marshalDomResult(Object graph, DOMResult domResult) throws XmlMappingException {
    Assert.notNull(domResult.getNode(), "DOMResult does not contain Node");
    marshalDomNode(graph, domResult.getNode());

    I dont understand if i need to override, redefine or anything else, could you please provide some advice?

    Any help will be highly appreciated

  • #2
    This is a bug. I have created INT-324 in JIRA.