public abstract class ExecutionLockProvider extends Object implements Service
| Modifier and Type | Field and Description |
|---|---|
static String |
KEY_SCOPE
The configuration key name of the lock scope.
|
| Constructor and Description |
|---|
ExecutionLockProvider() |
| Modifier and Type | Method and Description |
|---|---|
void |
configure(ServiceProfile<?> profile)
Configures this service.
|
protected abstract void |
doConfigure(ServiceProfile<?> profile)
Configures this provider internally (extention point).
|
protected abstract ExecutionLock |
newInstance(ExecutionLock.Scope lockScope,
String batchId)
Creates a new lock manager.
|
ExecutionLock |
newInstance(String batchId)
Creates a new lock manager.
|
public static final String KEY_SCOPE
ExecutionLock.Scope.
If this key is not specified, a default scope is selected.public final void configure(ServiceProfile<?> profile) throws InterruptedException, IOException
Serviceconfigure in interface Serviceprofile - the profile of this serviceInterruptedException - if interrupted in configurationIOException - if failed to configure this serviceprotected abstract void doConfigure(ServiceProfile<?> profile) throws InterruptedException, IOException
profile - the profile of this serviceInterruptedException - if interrupted in configurationIOException - if failed to configure this servicepublic final ExecutionLock newInstance(String batchId) throws IOException
batchId - the current batch IDIOException - if failed to acquire the lockIllegalArgumentException - if some parameters were nullprotected abstract ExecutionLock newInstance(ExecutionLock.Scope lockScope, String batchId) throws IOException
lockScope - target scopebatchId - the current batch IDIOException - if failed to acquire the lockCopyright © 2011–2019 Asakusa Framework Team. All rights reserved.