I've been doing some work on SWITCHYARD-59:
- core: https://github.com/tfennelly/jboss-switchyard-core/tree/SWITCHYARD-59
- components: https://github.com/tfennelly/jboss-switchyard-components/tree/SWITCHYARD-59
The point of this task is to get the SOAP and Bean components working more smootly together. We want to be able to easily invoke a bean component through the SOAPGateway. To make that work, we obviously need transformations applied as part of the Exchange mechanism in order to transform between the SOAP and Java domains... SOAP -> Java on the IN, Java to SOAP on the way OUT. So this work required changes in the following areas:
- Transformation related code changes to core in order to support the concept of a TransformSequence (ala pipelines) on an exchange. Also support fault exception transformation (e.g. transform an Exception into a SOAP fault).
- Modifications to the SOAP component for attaching IN and OUT TransformSequence info to the Exchange. The SOAP component uses the wsdl port + the target service operation metadata to work out the data types at each end of the IN and OUT phases of an Exchange. This data creates the TransformSequences. Magesh... would be great if you could review these changes too please!!
- A small mod to the CDI extension that automatically registers all beans that implement the Transformer interface (in the domain TransformerRegistry). This is experimental, but I do think it's quite neat. I also think we should (if it's kept) have a way of contolling it e.g. that the Transformer must have something like an @AutoLoad annotation for it to be automatically loaded into the transformation registry.
- A "Greeting" bean Service test example (in components/tests). The interface to this service uses semi-complex domain objects (i.e. more than just basic String/Number value types ala a Hello World example). Intentionally did this so as to exercise the transformation parts of the puzzle.
Still aving an issue with the transformation of Faults. I have a test there that generates an exception, which gets transformed into a soap fualt that looks OK. I'm just getting a 500 error from the test http invoker. Might be an issue with the test, but not sure.