I am using version 2.0.0-M3 of Smooks and am attempting to transform Json to XML using Freemarker with the <?TEMPLATE-SPLIT-PI?> processing instruction. However, I receive the error message:
org.smooks.api.SmooksException: Failed to filter source
I have attached a simple project with the test testJsonToXml. Any advise would be appreciated. Thanks.
The example input message is
{
"orderId": 34567,
"customerId": "A56787",
"orderTotal": 13.56,
"lineItems": [
{
"sku": "56789",
"price": 1.57
},
{
"sku": "4433",
"price": 11.57
}
]
}
The output should roughly be as follows:
<customer_order id="34567">
<customer_id>A56787</customer_id>
<total>13.56</total>
<line_item sku="56789">
<price>1.57</price>
</line_item>
<line_item sku="4433">
<price>11.57</price>
</line_item>
</customer_order>