it.imolinfo.jbi4ejb.jbi.component.runtime
Class InOutProviderMessageExchangeHandler

java.lang.Object
  extended by it.imolinfo.jbi4ejb.jbi.component.runtime.AbstractMessageExchangeHandler
      extended by it.imolinfo.jbi4ejb.jbi.component.runtime.InOutProviderMessageExchangeHandler
All Implemented Interfaces:
MessageExchangeHandler, java.lang.Runnable

public abstract class InOutProviderMessageExchangeHandler
extends AbstractMessageExchangeHandler

This class implements the InOut Message exchange handler implemenation for the Service Provider. It does a synchronous message exchange processing where it invokes the service and wait until the service processes the message and returns the response message. It then return out or fault message to consumer and also waits until the consumer returns the DONE status. Extended class should implement the actual invocation of the service operation by implementing the abstract method invokeInOutOperation of this class.

Author:
Sun Microsystems, Inc.

Field Summary
static long SEND_SYNC_TIMEOUT
           
 
Fields inherited from class it.imolinfo.jbi4ejb.jbi.component.runtime.AbstractMessageExchangeHandler
IN_MESSAGE, OUT_MESSAGE
 
Constructor Summary
InOutProviderMessageExchangeHandler()
          Creates a new instance of InOutProviderMessageExchangeHandler
 
Method Summary
protected abstract  boolean invokeOperation(javax.jbi.messaging.NormalizedMessage inMsg, javax.jbi.messaging.NormalizedMessage outMsg, javax.jbi.messaging.Fault fault)
           
protected  void processDone()
           
protected  void processError(java.lang.Exception ex)
           
protected  void processFault(javax.jbi.messaging.Fault fault)
           
protected  void processMessage()
           
 void sendFault(javax.jbi.messaging.Fault fault)
           
protected  void validateMessageExchange()
           
 
Methods inherited from class it.imolinfo.jbi4ejb.jbi.component.runtime.AbstractMessageExchangeHandler
getDeliveryChannel, getMessageExchange, processMessageExchange, run, send, sendDone, sendError, sendFault, sendFault, setMessageExchange
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SEND_SYNC_TIMEOUT

public static final long SEND_SYNC_TIMEOUT
See Also:
Constant Field Values
Constructor Detail

InOutProviderMessageExchangeHandler

public InOutProviderMessageExchangeHandler()
Creates a new instance of InOutProviderMessageExchangeHandler

Method Detail

validateMessageExchange

protected void validateMessageExchange()
                                throws javax.jbi.messaging.MessagingException
Specified by:
validateMessageExchange in class AbstractMessageExchangeHandler
Throws:
javax.jbi.messaging.MessagingException

processFault

protected void processFault(javax.jbi.messaging.Fault fault)
Specified by:
processFault in class AbstractMessageExchangeHandler

processDone

protected void processDone()
Specified by:
processDone in class AbstractMessageExchangeHandler

processError

protected void processError(java.lang.Exception ex)
Specified by:
processError in class AbstractMessageExchangeHandler

processMessage

protected final void processMessage()
Specified by:
processMessage in class AbstractMessageExchangeHandler

sendFault

public void sendFault(javax.jbi.messaging.Fault fault)
               throws javax.jbi.messaging.MessagingException
Overrides:
sendFault in class AbstractMessageExchangeHandler
Throws:
javax.jbi.messaging.MessagingException

invokeOperation

protected abstract boolean invokeOperation(javax.jbi.messaging.NormalizedMessage inMsg,
                                           javax.jbi.messaging.NormalizedMessage outMsg,
                                           javax.jbi.messaging.Fault fault)
                                    throws javax.jbi.messaging.MessagingException
Throws:
javax.jbi.messaging.MessagingException


Copyright © 2007-2008 Imola Informatica. All Rights Reserved.