4 Replies Latest reply on Aug 13, 2012 1:30 PM by Gary Brown

    Service operation (invocation contract) only supports one fault type

    Gary Brown Master

      I have a BPMN2 choreography that is generating a switchyard bean service where one of the operations returns two faults, and I get the following exception:

       

      org.switchyard.exception.SwitchYardException: Service operations on a Java interface can only throw one type of exception.

          at org.switchyard.metadata.java.JavaService$OperationTypeQNames.fault(JavaService.java:241)

          at org.switchyard.metadata.java.JavaService.fromClass(JavaService.java:103)

          at org.switchyard.deploy.internal.Deployment.loadServiceInterface(Deployment.java:319)

          at org.switchyard.deploy.internal.Deployment.getComponentServiceInterface(Deployment.java:303)

          at org.switchyard.deploy.internal.Deployment.deployImplementations(Deployment.java:392)

          at org.switchyard.deploy.internal.Deployment.start(Deployment.java:140)

       

      Was wondering why the invocation contract only supports one fault response type?

       

      Regards

      Gary