@Alpha public class FSDagStateStore extends Object implements DagStateStore
| Modifier and Type | Field and Description |
|---|---|
static String |
DAG_FILE_EXTENSION |
| Constructor and Description |
|---|
FSDagStateStore(com.typesafe.config.Config config,
Map<URI,TopologySpec> topologySpecMap) |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanUp(Dag<JobExecutionPlan> dag)
Delete the
Dag from the backing store, typically upon completion of execution. |
Dag<JobExecutionPlan> |
getDag(File dagFile)
Return a
Dag given a file name. |
List<Dag<JobExecutionPlan>> |
getDags()
Load all currently running
Dags from the underlying store. |
void |
writeCheckpoint(Dag<JobExecutionPlan> dag)
Persist the
Dag to the backing store. |
public static final String DAG_FILE_EXTENSION
public FSDagStateStore(com.typesafe.config.Config config,
Map<URI,TopologySpec> topologySpecMap)
throws IOException
IOExceptionpublic void writeCheckpoint(Dag<JobExecutionPlan> dag) throws IOException
Dag to the backing store.
This is not an actual checkpoint but more like a Write-ahead log, where uncommitted job will be persisted
and be picked up again when leader transition happens.writeCheckpoint in interface DagStateStoredag - The dag submitted to DagManagerIOExceptionpublic void cleanUp(Dag<JobExecutionPlan> dag)
Dag from the backing store, typically upon completion of execution.cleanUp in interface DagStateStoredag - The dag completed/cancelled from execution on SpecExecutor.public List<Dag<JobExecutionPlan>> getDags() throws IOException
Dags from the underlying store. Typically, invoked when a new DagManager
takes over or on restart of service.getDags in interface DagStateStoreList of currently running Dags.IOExceptionpublic Dag<JobExecutionPlan> getDag(File dagFile) throws IOException
Dag given a file name.dagFile - Dag associated with the dagFile.IOException