Error happens when undeploying SwitchYard application with transformers

Solution Unverified - Updated -

Issue

  • I’m having trouble with undeploying SwitchYard applications with pending requests and their response transformations.
  • It seems that after the JBoss FSW waits for all requests to be completed and undeploys the applications, all response transformations are skipped.
  • As an example, I have two simple SwitchYard applications: Hello and World.

    • The Hello application communicates with the World application using a SCA Binding.
    • The World application contains a bean that returns a WorldOutput object, but since the SCA Binding returns a String, I created the SCATransformer class to transform the response into a String.
    • All requests to the World application will take longer than 15 seconds, because it contains a Thread.sleep command.
    • After Hello application received a request and called the World application, I tried to undeploy the World application and the JBoss FSW waited for 30 seconds for all pending requests to be completed.
    • Afterwards, the application was undeployed and I got this exception:

      org.switchyard.HandlerException: SWITCHYARD014011: Transformations not applied.  Required payload type of 'java:java.lang.String'.  Actual payload type is 'java:com.example.switchyard.interfaces.WorldOutput'.  You must define and register a Transformer to transform between these types.
      
    • The Hello application received a response that was not transformed.

  • Does this exception make sense or is it a bug? If it’s not a bug, is there any workaround?

Environment

  • Red Hat JBoss Fuse
    • 6.2.x
  • Red Hat JBoss Fuse Service Works (FSW)
    • 6.0.x
  • SwitchYard

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content