khandelwal-prateek commented on code in PR #4113:
URL: https://github.com/apache/gobblin/pull/4113#discussion_r2252021542
##########
gobblin-runtime/src/main/java/org/apache/gobblin/runtime/Task.java:
##########
@@ -942,7 +970,14 @@ public void commit() {
if (failedForkIds.size() == 1 &&
holder.getThrowable(failedForkIds.get(0)).isPresent()) {
failTask(holder.getThrowable(failedForkIds.get(0)).get());
} else {
- failTask(holder.getAggregatedException(failedForkIds,
this.taskId));
+ String taskDataQualityString =
taskState.getProp(ConfigurationKeys.TASK_LEVEL_POLICY_RESULT_KEY);
+ DataQualityStatus dataQualityStatus =
DataQualityStatus.NOT_EVALUATED;
+ if(taskDataQualityString != null) {
Review Comment:
nit: `if (`. Please check formatting at all places
##########
gobblin-runtime/src/test/java/org/apache/gobblin/quality/DataQualityEvaluatorTest.java:
##########
@@ -0,0 +1,263 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.gobblin.quality;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Properties;
+import org.apache.gobblin.configuration.ConfigurationKeys;
+import org.apache.gobblin.metrics.event.TimingEvent;
+import org.apache.gobblin.qualitychecker.DataQualityStatus;
+import org.apache.gobblin.runtime.JobState;
+import org.apache.gobblin.runtime.TaskState;
+import org.apache.gobblin.service.ServiceConfigKeys;
+import org.testng.Assert;
+import org.testng.annotations.Test;
+
+/**
+ * Unit tests for {@link DataQualityEvaluator}
+ */
+@Test(groups = {"gobblin.quality"})
+public class DataQualityEvaluatorTest {
+
+ @Test
Review Comment:
use 2 spaces for indentation.. as mentioned earlier, please refer to
https://gobblin.apache.org/docs/developer-guide/CodingStyle/ to import the
codestyle xml in IDE which would automatically set indentation to 2 spaces
--
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]