Vordel SDK

com.vordel.circuit
Class FilterPathTracker

java.lang.Object
  extended by com.vordel.circuit.MessageListenerAdapter
      extended by com.vordel.circuit.FilterPathTracker
All Implemented Interfaces:
MessageCreationListener, MessageListener

public class FilterPathTracker
extends MessageListenerAdapter
implements MessageCreationListener


Constructor Summary
FilterPathTracker()
           
 
Method Summary
 void dispose()
           
 CircuitTracker getCircuitTracker(Message m)
           
 void messageCreated(Message m, java.lang.Object source)
          Called once the message is created, but before the source has populated any properties.
 void postCircuitInvocation(Circuit c, Message m, boolean result, java.lang.Object context)
          Called after a chain of Filters in the Circuit has been invoked.
 void postCircuitProcessing(Message message, int result)
          Called when all processing in the Circuit-space is completed.
 void postFilterInvocation(Circuit c, MessageProcessor mp, Message m, int resultType, MessageProcessor caller, java.lang.Object context)
          This method is called when a Filter's MessageProcessor has finished execution.
 void preCircuitInvocation(Circuit c, Message m, java.lang.Object context)
          Called before the first Filter in a given Circuit is invoked.
 void preCircuitProcessing(Circuit c, Message m, java.lang.Object context)
          Called when the message originator has completed initializing the Message, and we are about to start processing in the Circuit-space.
 void preFaultHandlerInvocation(Circuit c, MessageProcessor faultHandler, Message m, CircuitAbortException fault)
          Called before attempting to handle a previous CircuitAbortException with a specific fault-handling MessageProcessor.
 void preFilterInvocation(Circuit c, MessageProcessor mp, Message m, MessageProcessor caller, java.lang.Object context)
          This method is called immediately before a Filter's MessageProcessor is invoked.
static void tracePath(CircuitCallRecord cip, int level)
           
 
Methods inherited from class com.vordel.circuit.MessageListenerAdapter
abortedCircuitInvocation, onMessageCompletion
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FilterPathTracker

public FilterPathTracker()
Method Detail

dispose

public void dispose()

getCircuitTracker

public CircuitTracker getCircuitTracker(Message m)

preCircuitInvocation

public void preCircuitInvocation(Circuit c,
                                 Message m,
                                 java.lang.Object context)
Description copied from interface: MessageListener
Called before the first Filter in a given Circuit is invoked.

Specified by:
preCircuitInvocation in interface MessageListener
Overrides:
preCircuitInvocation in class MessageListenerAdapter
Parameters:
c - The Circuit about to be called.
m - The Message.
context - The context in which this circuit was called. In the case of the circuit being run via a reference from a filter, it may be null, an ESPK, or a String property which resolves to this circuit. In the case of the circuit being run from the Transport module, it will be that module itself (as per the 'source' parameter in Message.addCreationListener(com.vordel.circuit.MessageCreationListener)), or null if no source was specified to the creation callback.

postCircuitInvocation

public void postCircuitInvocation(Circuit c,
                                  Message m,
                                  boolean result,
                                  java.lang.Object context)
Description copied from interface: MessageListener
Called after a chain of Filters in the Circuit has been invoked.

Specified by:
postCircuitInvocation in interface MessageListener
Overrides:
postCircuitInvocation in class MessageListenerAdapter
Parameters:
c - The Circuit.
m - The Message.
result - The status which the Circuit returned - True if the Circuit passed, False if it failed. If it aborted, the MessageListener.abortedCircuitInvocation(com.vordel.circuit.Circuit, com.vordel.circuit.Message, com.vordel.circuit.CircuitAbortException) method is called instead.

preFilterInvocation

public void preFilterInvocation(Circuit c,
                                MessageProcessor mp,
                                Message m,
                                MessageProcessor caller,
                                java.lang.Object context)
Description copied from interface: MessageListener
This method is called immediately before a Filter's MessageProcessor is invoked.

Specified by:
preFilterInvocation in interface MessageListener
Overrides:
preFilterInvocation in class MessageListenerAdapter
Parameters:
c - The Circuit context in which this processor was called.
mp - The MessageProcessor about to be invoked.
m - The Message before the processor works on it.
caller - The MessageProcessor which is calling this processor. Usually this is null, as the Circuit is the implicit caller of the processor. However, some processors are compound processors, i.e. they are themselves made up of other processors. In these cases, it's the caller processor which invokes the 'mp' in the context of the caller's Circuit. When this happens, the 'caller' parameter will be non-null.

postFilterInvocation

public void postFilterInvocation(Circuit c,
                                 MessageProcessor mp,
                                 Message m,
                                 int resultType,
                                 MessageProcessor caller,
                                 java.lang.Object context)
Description copied from interface: MessageListener
This method is called when a Filter's MessageProcessor has finished execution.

Specified by:
postFilterInvocation in interface MessageListener
Overrides:
postFilterInvocation in class MessageListenerAdapter
Parameters:
c - The Circuit context in which this processor was called.
mp - The MessageProcessor which was invoked.
m - The Message as populated after invocation.
resultType - one of
caller - The MessageProcessor which called this processor. Usually this is null. See MessageListener.preFilterInvocation(com.vordel.circuit.Circuit, com.vordel.circuit.MessageProcessor, com.vordel.circuit.Message, com.vordel.circuit.MessageProcessor, java.lang.Object).

preCircuitProcessing

public void preCircuitProcessing(Circuit c,
                                 Message m,
                                 java.lang.Object context)
Description copied from interface: MessageListener
Called when the message originator has completed initializing the Message, and we are about to start processing in the Circuit-space.

Specified by:
preCircuitProcessing in interface MessageListener
Overrides:
preCircuitProcessing in class MessageListenerAdapter
Parameters:
c - The Circuit which is about to be invoked.
m - The Message.
context - The Message originator, or null.

postCircuitProcessing

public void postCircuitProcessing(Message message,
                                  int result)
Description copied from interface: MessageListener
Called when all processing in the Circuit-space is completed.

Specified by:
postCircuitProcessing in interface MessageListener
Overrides:
postCircuitProcessing in class MessageListenerAdapter
Parameters:
message - The Message.
result - The result of Circuit processing. One of:

preFaultHandlerInvocation

public void preFaultHandlerInvocation(Circuit c,
                                      MessageProcessor faultHandler,
                                      Message m,
                                      CircuitAbortException fault)
Description copied from interface: MessageListener
Called before attempting to handle a previous CircuitAbortException with a specific fault-handling MessageProcessor.

Specified by:
preFaultHandlerInvocation in interface MessageListener
Overrides:
preFaultHandlerInvocation in class MessageListenerAdapter
Parameters:
c - The Circuit in whose context the faultHander will execute.
faultHandler - The fault handler MessageProcessor we're about to invoke.
m - The Message.
fault - The CircuitAbortException which brought us here.

tracePath

public static void tracePath(CircuitCallRecord cip,
                             int level)

messageCreated

public void messageCreated(Message m,
                           java.lang.Object source)
Description copied from interface: MessageCreationListener
Called once the message is created, but before the source has populated any properties.

Specified by:
messageCreated in interface MessageCreationListener
Parameters:
m - The newly created Message.
source - The originator of the message. Usually a transport module, it may be null.

Vordel SDK


This documentation and all its contents and graphics, copyright © 1999 - 2011 Vordel