Mukvin commented on code in PR #2017:
URL: https://github.com/apache/kylin/pull/2017#discussion_r1022241375


##########
kylin-spark-project/kylin-spark-engine/src/main/java/org/apache/kylin/engine/spark/job/NSparkCubingJob.java:
##########
@@ -158,4 +158,19 @@ public void cleanupAfterJobDiscard(String segmentName, 
String segmentIdentifier)
             logger.warn("Delete resource file failed after job be discarded, 
due to", e);
         }
     }
+
+    public void cleanupJobTempAfterJobDiscard() {
+        PathManager.deleteJobTempPath(getConfig(), 
getParam(MetadataConstants.P_PROJECT_NAME),
+                getParam(MetadataConstants.P_JOB_ID));
+    }
+
+    public void cleanupSegmentAfterJobDiscard(String segmentName, String 
segmentIdentifier) {
+        try {
+            CubeManager cubeManager = CubeManager.getInstance(getConfig());
+            CubeInstance cube = 
cubeManager.getCube(getParam(MetadataConstants.P_CUBE_NAME));
+            PathManager.deleteSegmentParquetStoragePath(cube, segmentName, 
segmentIdentifier);

Review Comment:
   How can I get the notice that segments were deleted success?
   Adding a piece of extra log information may be good that the progress is in 
this place.



-- 
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]

Reply via email to