2 Replies Latest reply on May 17, 2013 8:47 AM by Keith Babo

    Smooks transformation switchyard.xml

    Arpit Saxena Newbie



      In my switchyard.xml while doing smooks transformation


      <trfm:transform.smooks xmlns:trfm="urn:switchyard-config:transform:1.0" config="/smooks/OrderAck_XML.xml" from="java:org.switchyard.quickstarts.transform.smooks.OrderAck" to="{urn:switchyard-quickstart:transform-smooks:1.0}submitOrderResponse" type="JAVA2XML"/>


      , if i change submitOrderResponse to submitOrderResponse1 ,it shows me an error.


      Required payload type of '{urn:switchyard-quickstart:transform-smooks:1.0}submitOrderResponse'.  Actual payload type is 'java:org.switchyard.quickstarts.transform.smooks.OrderAck'.  You must define and register a Transformer to transform between these types.



      I dont understand where else the mapping is done from OrderAck to submitOrderResponse


      According to my understanding (which is very elementary) , I am doing this mapping in switchyard.xml and if i change to submitorderresponse1 it should not even talk about submitorderresponse.


      Please reply

        • 1. Re: Smooks transformation switchyard.xml
          Arpit Saxena Newbie

          Is there any Directory where all the mappings are placed. For eg. If i change the name of Service Bean and Servie interface everywhere , the build should be succesful. But it still finds the old OrderService bean and saus that there is no mapping for it.


          Error : No registered service found for {urn:switchyard-quickstart:transform-smooks:0.1.0}OrderService

          • 2. Re: Smooks transformation switchyard.xml
            Keith Babo Master

            The coordinates for transformation (from type, to type) are determined based on the interfaces you used for services and references.  That's how declarative transformation works in SY.  When a service is invoked, we know the consumer's and the provider's contract, so we can lookup a transformation for you instead of requiring you to explicitly invoke the transformation.  If you have a question about a specific application it's best to post the actual app to the thread.  If you change the name of Java classes used as implementations or service interfaces, you need to make sure that the switchyard.xml is updated as well to include the changes.