@InterfaceAudience.Private @InterfaceStability.Evolving public interface ProcedureStore
Modifier and Type | Interface and Description |
---|---|
static interface |
ProcedureStore.ProcedureStoreListener
Store listener interface.
|
Modifier and Type | Method and Description |
---|---|
void |
delete(long procId)
The specified procId was removed from the executor,
due to completion, abort or failure.
|
int |
getNumThreads() |
void |
insert(Procedure proc,
Procedure[] subprocs)
When a procedure is submitted to the executor insert(proc, null) will be called.
|
boolean |
isRunning() |
Iterator<Procedure> |
load()
Load the Procedures in the store.
|
void |
recoverLease()
Acquire the lease for the procedure store.
|
void |
registerListener(ProcedureStore.ProcedureStoreListener listener)
Add the listener to the notification list.
|
void |
start(int numThreads)
Start/Open the procedure store
|
void |
stop(boolean abort)
Stop/Close the procedure store
|
boolean |
unregisterListener(ProcedureStore.ProcedureStoreListener listener)
Remove the listener from the notification list.
|
void |
update(Procedure proc)
The specified procedure was executed,
and the new state should be written to the store.
|
void registerListener(ProcedureStore.ProcedureStoreListener listener)
listener
- The AssignmentListener to registerboolean unregisterListener(ProcedureStore.ProcedureStoreListener listener)
listener
- The AssignmentListener to unregistervoid start(int numThreads) throws IOException
numThreads
- IOException
void stop(boolean abort)
abort
- true if the stop is an abortboolean isRunning()
int getNumThreads()
void recoverLease() throws IOException
IOException
Iterator<Procedure> load() throws IOException
IOException
void insert(Procedure proc, Procedure[] subprocs)
proc
- the procedure to serialize and write to the store.subprocs
- the newly created child of the proc.void update(Procedure proc)
proc
- the procedure to serialize and write to the store.void delete(long procId)
procId
- the ID of the procedure to remove.Copyright © 2007-2016 The Apache Software Foundation. All Rights Reserved.