public abstract class KafkaJobStatusMonitor extends HighLevelConsumer<byte[],byte[]>
GobblinTrackingEvents reporting statuses of
running jobs. The job statuses are stored as State objects in
a FileContextBasedFsStateStore.| Modifier and Type | Field and Description |
|---|---|
static String |
GET_AND_SET_JOB_STATUS |
static String |
STATE_STORE_KEY_SEPARATION_CHARACTER |
static String |
STATE_STORE_TABLE_SUFFIX |
config, CONSUMER_CLIENT_FACTORY_CLASS_KEY, DEFAULT_AUTO_COMMIT_VALUE, DEFAULT_OFFSET_COMMIT_NUM_RECORDS_THRESHOLD, DEFAULT_OFFSET_COMMIT_TIME_THRESHOLD_SECS, ENABLE_AUTO_COMMIT_KEY, GROUP_ID_KEY, OFFSET_COMMIT_NUM_RECORDS_THRESHOLD_KEY, OFFSET_COMMIT_TIME_THRESHOLD_SECS_KEY, topic| Constructor and Description |
|---|
KafkaJobStatusMonitor(String topic,
com.typesafe.config.Config config,
int numThreads) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
createMetrics() |
static long |
getExecutionIdFromTableName(String tableName) |
static String |
jobStatusStoreName(String flowGroup,
String flowName) |
static String |
jobStatusTableName(long flowExecutionId,
String jobGroup,
String jobName) |
static String |
jobStatusTableName(String flowExecutionId,
String jobGroup,
String jobName) |
abstract State |
parseJobStatus(byte[] message) |
protected void |
processMessage(org.apache.gobblin.kafka.client.DecodeableKafkaRecord<byte[],byte[]> message) |
void |
shutDown() |
protected void |
startUp() |
buildMetricsContextAndMetrics, commitOffsets, createConsumerClient, getGobblinKafkaConsumerClient, getMetricContext, getTagsForMetrics, getTopic, shutdownMetricspublic static final String STATE_STORE_TABLE_SUFFIX
public static final String STATE_STORE_KEY_SEPARATION_CHARACTER
public static final String GET_AND_SET_JOB_STATUS
public KafkaJobStatusMonitor(String topic, com.typesafe.config.Config config, int numThreads) throws ReflectiveOperationException
ReflectiveOperationExceptionprotected void startUp()
startUp in class HighLevelConsumer<byte[],byte[]>public void shutDown()
shutDown in class HighLevelConsumer<byte[],byte[]>protected void createMetrics()
createMetrics in class HighLevelConsumer<byte[],byte[]>protected void processMessage(org.apache.gobblin.kafka.client.DecodeableKafkaRecord<byte[],byte[]> message)
processMessage in class HighLevelConsumer<byte[],byte[]>public static String jobStatusTableName(String flowExecutionId, String jobGroup, String jobName)
public static String jobStatusTableName(long flowExecutionId, String jobGroup, String jobName)
public static long getExecutionIdFromTableName(String tableName)
public abstract State parseJobStatus(byte[] message) throws IOException
IOException