org.mule.util.store
Class AbstractMonitoredObjectStore

java.lang.Object
  extended by org.mule.util.store.AbstractMonitoredObjectStore
All Implemented Interfaces:
Runnable, MuleContextAware, Disposable, Initialisable, ObjectStore
Direct Known Subclasses:
InMemoryObjectStore

public abstract class AbstractMonitoredObjectStore
extends Object
implements ObjectStore, Runnable, MuleContextAware, Initialisable, Disposable

TODO


Field Summary
protected  MuleContext context
           
protected  int entryTTL
           
protected  int expirationInterval
           
protected  Log logger
           
protected  int maxEntries
           
protected  String name
           
protected  edu.emory.mathcs.backport.java.util.concurrent.ScheduledThreadPoolExecutor scheduler
          Default constructor for IdempotentInMemoryMessageIdStore.
 
Fields inherited from interface org.mule.api.lifecycle.Initialisable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Disposable
PHASE_NAME
 
Constructor Summary
AbstractMonitoredObjectStore()
           
 
Method Summary
 void dispose()
          A lifecycle method where implementor should free up any resources.
protected abstract  void expire()
           
 int getEntryTTL()
           
 int getExpirationInterval()
           
 int getMaxEntries()
           
 String getName()
           
 edu.emory.mathcs.backport.java.util.concurrent.ScheduledThreadPoolExecutor getScheduler()
           
 void initialise()
          Method used to perform any initialisation work.
 void run()
           
 void setEntryTTL(int entryTTL)
           
 void setExpirationInterval(int expirationInterval)
           
 void setMaxEntries(int maxEntries)
           
 void setMuleContext(MuleContext context)
           
 void setName(String id)
           
 void setScheduler(edu.emory.mathcs.backport.java.util.concurrent.ScheduledThreadPoolExecutor scheduler)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mule.api.store.ObjectStore
containsObject, removeObject, retrieveObject, storeObject
 

Field Detail

logger

protected final Log logger

scheduler

protected edu.emory.mathcs.backport.java.util.concurrent.ScheduledThreadPoolExecutor scheduler
Default constructor for IdempotentInMemoryMessageIdStore.


maxEntries

protected int maxEntries

entryTTL

protected int entryTTL

expirationInterval

protected int expirationInterval

name

protected String name

context

protected MuleContext context
Constructor Detail

AbstractMonitoredObjectStore

public AbstractMonitoredObjectStore()
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

run

public final void run()
Specified by:
run in interface Runnable

dispose

public void dispose()
A lifecycle method where implementor should free up any resources. If an exception is thrown it should just be logged and processing should continue. This method should not throw Runtime exceptions.

Specified by:
dispose in interface Disposable

setEntryTTL

public void setEntryTTL(int entryTTL)

setExpirationInterval

public void setExpirationInterval(int expirationInterval)

setMaxEntries

public void setMaxEntries(int maxEntries)

setScheduler

public void setScheduler(edu.emory.mathcs.backport.java.util.concurrent.ScheduledThreadPoolExecutor scheduler)

setName

public void setName(String id)

setMuleContext

public void setMuleContext(MuleContext context)
Specified by:
setMuleContext in interface MuleContextAware

getEntryTTL

public int getEntryTTL()

getExpirationInterval

public int getExpirationInterval()

getMaxEntries

public int getMaxEntries()

getName

public String getName()

getScheduler

public edu.emory.mathcs.backport.java.util.concurrent.ScheduledThreadPoolExecutor getScheduler()

expire

protected abstract void expire()


Copyright © 2003-2009 MuleSource, Inc.. All Rights Reserved.