Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.mule.routing
Class IdempotentMessageFilter

    java.lang.Object
      org.mule.processor.AbstractInterceptingMessageProcessor
          org.mule.processor.AbstractFilteringMessageProcessor
              org.mule.routing.IdempotentMessageFilter

All Implemented Interfaces:
  FlowConstructAware, Initialisable, InterceptingMessageProcessor, MessageProcessor, MessageSource

Direct Known Subclasses:
  IdempotentSecureHashMessageFilter

    public class IdempotentMessageFilter

extends AbstractFilteringMessageProcessor
implements FlowConstructAware, Initialisable

`IdempotentMessageFilter` ensures that only unique messages are passed on. It does this by checking the unique ID of the incoming message. Note that the underlying endpoint must support unique message IDs for this to work, otherwise a `UniqueIdNotSupportedException` is thrown.

EIP Reference: http://www.eaipatterns.com/IdempotentReceiver.html

Field Summary
`protected String` | `assignedComponentName`
`protected FlowConstruct` | `flowConstruct`
`protected String` | `idExpression`
`protected ObjectStore<String>` | `store`

Fields inherited from class org.mule.processor.AbstractFilteringMessageProcessor
`throwOnUnaccepted, unacceptedMessageProcessor`

Fields inherited from class org.mule.processor.AbstractInterceptingMessageProcessor
`logger, next`

Fields inherited from interface org.mule.api.lifecycle.Initialisable
`PHASE_NAME`

Constructor Summary
`IdempotentMessageFilter()`

Method Summary
`protected boolean` | `accept(MuleEvent event)`
`protected boolean` | `acceptMessageForFlowConstruct(MuleEvent event)`
`protected ObjectStore<String>` | `createMessageIdStore()`
`String` | `getIdExpression()`
`protected String` | `getIdForEvent(MuleEvent event)`
`ObjectStore<String>` | `getStore()`
`void` | `initialise()` Method used to perform any initialisation work.
`protected boolean` | `isNewMessage(MuleEvent event)`
`protected MuleEvent` | `processNext(MuleEvent event)`
`void` | `setFlowConstruct(FlowConstruct flowConstruct)`
`void` | `setIdExpression(String idExpression)`
`void` | `setStore(ObjectStore<String> store)`

Methods inherited from class org.mule.processor.AbstractFilteringMessageProcessor
`filterUnacceptedException, getUnacceptedMessageProcessor, handleUnaccepted, isThrowOnUnaccepted, process, setThrowOnUnaccepted, setUnacceptedMessageProcessor`

Methods inherited from class org.mule.processor.AbstractInterceptingMessageProcessor
`setListener, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### store

    protected volatile ObjectStore<String> store

### assignedComponentName

    protected volatile String assignedComponentName

### flowConstruct

    protected FlowConstruct flowConstruct

### idExpression

    protected String idExpression

Constructor Detail

### IdempotentMessageFilter

    public IdempotentMessageFilter()

Method Detail

### initialise

    public void initialise()
                    throws InitialisationException

  Description copied from interface: `Initialisable`
  Method used to perform any initialisation work. If a fatal error occurs during initialisation an `InitialisationException` should be thrown, causing the Mule instance to shutdown. If the error is recoverable, say by retrying to connect, a `RecoverableException` should be thrown. There is no guarantee that by throwing a Recoverable exception that the Mule instance will not shut down.

  Specified by:
    `initialise` in interface `Initialisable`
  Throws:
    `InitialisationException` - if a fatal error occurs causing the Mule instance to shutdown
    `RecoverableException` - if an error occurs that can be recovered from

### createMessageIdStore

    protected ObjectStore<String> createMessageIdStore()
                                                throws InitialisationException

  Throws:
    `InitialisationException`

### processNext

    protected MuleEvent processNext(MuleEvent event)
                             throws MuleException

  Overrides:
    `processNext` in class `AbstractInterceptingMessageProcessor`
  Throws:
    `MuleException`

### getIdForEvent

    protected String getIdForEvent(MuleEvent event)
                            throws MessagingException

  Throws:
    `MessagingException`

### getIdExpression

    public String getIdExpression()

### setIdExpression

    public void setIdExpression(String idExpression)

### getStore

    public ObjectStore<String> getStore()

### setStore

    public void setStore(ObjectStore<String> store)

### accept

    protected boolean accept(MuleEvent event)

  Specified by:
    `accept` in class `AbstractFilteringMessageProcessor`

### acceptMessageForFlowConstruct

    protected boolean acceptMessageForFlowConstruct(MuleEvent event)

### isNewMessage

    protected boolean isNewMessage(MuleEvent event)

### setFlowConstruct

    public void setFlowConstruct(FlowConstruct flowConstruct)

  Specified by:
    `setFlowConstruct` in interface `FlowConstructAware`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003-2010 MuleSoft, Inc.. All Rights Reserved.