public class MuleLockFactory extends Object implements LockFactory, MuleContextAware, Initialisable, Disposable
PHASE_NAME
PHASE_NAME
Constructor and Description |
---|
MuleLockFactory() |
Modifier and Type | Method and Description |
---|---|
Lock |
createLock(String lockId)
Provides a lock to create thread safe Mule components.
|
void |
dispose()
A lifecycle method where implementor should free up any resources.
|
void |
initialise()
Method used to perform any initialisation work.
|
void |
setLockProvider(LockProvider lockProvider) |
void |
setMuleContext(MuleContext context) |
public Lock createLock(String lockId)
LockFactory
createLock
in interface LockFactory
lockId
- Id of the lockLock
instance associated to the lockIdpublic void dispose()
Disposable
dispose
in interface Disposable
public void initialise() throws InitialisationException
Initialisable
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.initialise
in interface Initialisable
InitialisationException
- if a fatal error occurs causing the Mule instance to shutdownRecoverableException
- if an error occurs that can be recovered frompublic void setLockProvider(LockProvider lockProvider)
public void setMuleContext(MuleContext context)
setMuleContext
in interface MuleContextAware
Copyright © 2003–2015 MuleSoft, Inc.. All rights reserved.