* @see edu.indiana.extreme.xbaya.workflow.WorkflowInvoker#invoke()
*/
public synchronized void invoke() throws XBayaException {
try{
WSIFMessage inputMessage = this.invoker.getInputs();
logger.finest("inputMessage: "
+ XMLUtil.xmlElementToString((XmlElement) inputMessage));
this.notifier.invokingService(inputMessage);
ExecutorService executor = Executors.newSingleThreadExecutor();
this.result = executor.submit(new Callable<Boolean>() {
@SuppressWarnings("boxing")
public Boolean call() {
try {
boolean success = WorkflowInvokerWrapperForGFacInvoker.this.invoker.invoke();
if (success) {
// Send notification
WSIFMessage outputMessage = WorkflowInvokerWrapperForGFacInvoker.this.invoker
.getOutputs();
// An implementation of WSIFMessage,
// WSIFMessageElement, implements toString(), which
// serialize the message XML.
logger.finest("outputMessage: " + outputMessage);
WorkflowInvokerWrapperForGFacInvoker.this.notifier
.serviceFinished(outputMessage);
} else {
WSIFMessage faultMessage = WorkflowInvokerWrapperForGFacInvoker.this.invoker
.getFault();
// An implementation of WSIFMessage,
// WSIFMessageElement, implements toString(), which
// serialize the message XML.
logger.finest("received fault: " + faultMessage);