public class CassandraCommitter extends CheckpointCommitter
Entries are in the form |operator_id | subtask_id | last_completed_checkpoint|
jobId, LOG, operatorId
Constructor and Description |
---|
CassandraCommitter(ClusterBuilder builder) |
CassandraCommitter(ClusterBuilder builder,
String keySpace) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the resource/connection to it.
|
void |
commitCheckpoint(int subtaskIdx,
long checkpointId)
Mark the given checkpoint as completed in the resource.
|
void |
createResource()
Generates the necessary tables to store information.
|
boolean |
isCheckpointCommitted(int subtaskIdx,
long checkpointId)
Checked the resource whether the given checkpoint was committed completely.
|
void |
open()
Opens/connects to the resource, and possibly creates it beforehand.
|
void |
setJobId(String id)
Internally used to set the job ID after instantiation.
|
setOperatorId
public CassandraCommitter(ClusterBuilder builder)
public CassandraCommitter(ClusterBuilder builder, String keySpace)
public void setJobId(String id) throws Exception
setJobId
in class CheckpointCommitter
Exception
public void createResource() throws Exception
createResource
in class CheckpointCommitter
Exception
public void open() throws Exception
CheckpointCommitter
open
in class CheckpointCommitter
Exception
public void close() throws Exception
CheckpointCommitter
close
in class CheckpointCommitter
Exception
public void commitCheckpoint(int subtaskIdx, long checkpointId)
CheckpointCommitter
commitCheckpoint
in class CheckpointCommitter
subtaskIdx
- the index of the subtask responsible for committing the checkpoint.checkpointId
- the id of the checkpoint to be committed.public boolean isCheckpointCommitted(int subtaskIdx, long checkpointId)
CheckpointCommitter
isCheckpointCommitted
in class CheckpointCommitter
subtaskIdx
- the index of the subtask responsible for committing the checkpoint.checkpointId
- the id of the checkpoint we are interested in.Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.