homatthew commented on code in PR #3494:
URL: https://github.com/apache/gobblin/pull/3494#discussion_r859057458
##########
gobblin-compaction/src/main/java/org/apache/gobblin/compaction/mapreduce/MRCompactionTask.java:
##########
@@ -101,14 +106,19 @@ public void run() {
public void onMRTaskComplete (boolean isSuccess, Throwable throwable) {
if (isSuccess) {
try {
- setCounterInfo(taskContext.getTaskState());
+ TaskState taskState = taskContext.getTaskState();
+ setCounterInfo(taskState);
List<CompactionCompleteAction> actions =
this.suite.getCompactionCompleteActions();
for (CompactionCompleteAction action: actions) {
action.addEventSubmitter(eventSubmitter);
action.onCompactionJobComplete(dataset);
}
submitEvent(CompactionSlaEventHelper.COMPACTION_COMPLETED_EVENT_NAME);
+ if (dataset instanceof FileSystemDataset) {
Review Comment:
We can only check / persist the state for FileSystemDataset based compaction
jobs, so we needs this typecheck here.
The
[CompactionSuiteBaseWithConfigurableCompleteAction.java](https://github.com/apache/gobblin/commit/a77250b057e1ba83531ee0bed6e8302ed6c18510#diff-3befde2a879553d0eb7deb8a0c9b48951dc1c26c6bcf9fe86701bbfaf3c295df)
and
[CompactionSuiteBase.java](https://github.com/apache/gobblin/blob/d9ae5353c74fdcd385835fca9b586b3fdb90971b/gobblin-compaction/src/main/java/org/apache/gobblin/compaction/suite/CompactionSuiteBase.java)
both implement `CompactionSuite<FileSystemDataset>`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]