public class IdempotentSecureHashReceiver extends IdempotentReceiver
IdempotentSecureHashReceiver
ensures that only unique messages are
received by a service. It does this by calculating the SHA-256 hash of the message
itself. This provides a value with an infinitesimally small chance of a collision. This
can be used to filter message duplicates. Please keep in mind that the hash is
calculated over the entire byte array representing the message, so any leading or
trailing spaces or extraneous bytes (like padding) can produce different hash values
for the same semantic message content. Care should be taken to ensure that messages do
not contain extraneous bytes. This class is useful when the message does not support
unique identifiers.assignedComponentName, idExpression, store
logger
muleContext
PHASE_NAME
PHASE_NAME
Constructor and Description |
---|
IdempotentSecureHashReceiver() |
Modifier and Type | Method and Description |
---|---|
protected String |
getIdForEvent(MuleEvent event) |
String |
getMessageDigestAlgorithm() |
void |
setMessageDigestAlgorithm(String messageDigestAlgorithm) |
createMessageIdStore, getIdExpression, getStore, initialize, isMatch, process, setIdExpression, setStore
getFilter, getMessageInfoMapping, isTransformFirst, setFilter, setMessageInfoMapping, setTransformFirst
dispose, getMuleContext, getRouterStatistics, initialise, setMuleContext, setRouterStatistics
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getRouterStatistics, setRouterStatistics
initialise
dispose
protected String getIdForEvent(MuleEvent event) throws MessagingException
getIdForEvent
in class IdempotentReceiver
MessagingException
public String getMessageDigestAlgorithm()
public void setMessageDigestAlgorithm(String messageDigestAlgorithm)
Copyright © 2003–2013 MuleSource, Inc.. All rights reserved.