atg.commerce.fulfillment.processor
Class ProcExtractOrderId
java.lang.Object
atg.commerce.fulfillment.processor.ProcExtractOrderId
- All Implemented Interfaces:
- PipelineProcessor
public class ProcExtractOrderId
- extends java.lang.Object
- implements PipelineProcessor
This processor uses the ClientLockManager to guarrantee that only one thread
dealing with a message for a given key is running through the system at any
moment in time. The key used to acquire the lock is returned by the method
getKeyForMessage().
Field Summary |
static java.lang.String |
CLASS_VERSION
Class version string |
Method Summary |
protected java.lang.String |
getKeyForMessage(java.lang.String messageType,
CommerceMessage cMessage)
This method will return the key to be used for locking out other messages with the same
key while a thread is handling this message. |
int[] |
getRetCodes()
Returns the valid return codes
1 - The processor completed |
int |
runProcess(java.lang.Object pParam,
PipelineResult pResult)
This method gets a message received by a Fulfiller router and locks it by
calling the getKeyForMessage routine. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CLASS_VERSION
public static java.lang.String CLASS_VERSION
- Class version string
ProcExtractOrderId
public ProcExtractOrderId()
getRetCodes
public int[] getRetCodes()
- Returns the valid return codes
1 - The processor completed
- Specified by:
getRetCodes
in interface PipelineProcessor
- Returns:
- an integer array of the valid return codes.
runProcess
public int runProcess(java.lang.Object pParam,
PipelineResult pResult)
throws java.lang.Exception
- This method gets a message received by a Fulfiller router and locks it by
calling the getKeyForMessage routine.
This method requires that a JMS message and OrderFulfiller object be supplied
in pParam in a HashMap. Use the PipelineConstants class' static members to key
the objects in the HashMap.
- Specified by:
runProcess
in interface PipelineProcessor
- Parameters:
pParam
- a HashMap which must contain a JMS message and OrderFulfiller objectpResult
- a PipelineResult object which stores any information which must
be returned from this method invokation
- Returns:
- an integer specifying the processor's return code
- Throws:
java.lang.Exception
- throws any exception back to the caller- See Also:
PipelineProcessor.runProcess(Object, PipelineResult)
getKeyForMessage
protected java.lang.String getKeyForMessage(java.lang.String messageType,
CommerceMessage cMessage)
throws InvalidParameterException
- This method will return the key to be used for locking out other messages with the same
key while a thread is handling this message.
- Parameters:
pMessage
- the ObjectMessage containing the CommerceMessage.
- Returns:
- an Object which serves as the key for the message
- Throws:
InvalidParameterException