akkio-97 commented on a change in pull request #3515: [CARBONDATA-3623]: Fixed 
global sort compaction failure on timestamp column
URL: https://github.com/apache/carbondata/pull/3515#discussion_r361925792
 
 

 ##########
 File path: 
integration/spark2/src/main/scala/org/apache/carbondata/spark/rdd/CarbonTableCompactor.scala
 ##########
 @@ -374,17 +365,32 @@ class CarbonTableCompactor(carbonLoadModel: 
CarbonLoadModel,
       sparkSession: SparkSession,
       carbonLoadModel: CarbonLoadModel,
       carbonMergerMapping: CarbonMergerMapping): Array[(String, Boolean)] = {
+    val carbonTable = carbonLoadModel.getCarbonDataLoadSchema.getCarbonTable
     val splits = splitsOfSegments(
       sparkSession,
-      carbonLoadModel.getCarbonDataLoadSchema.getCarbonTable,
+      carbonTable,
       carbonMergerMapping.validSegments)
-    val dataFrame = DataLoadProcessBuilderOnSpark.createInputDataFrame(
-      sparkSession,
-      carbonLoadModel.getCarbonDataLoadSchema.getCarbonTable,
-      splits.asScala)
+    val dataFrame = try {
+      // segments to be compacted are set in the threadset() in carbon 
session, and unset in the end
 
 Review comment:
   During custom compaction it might so happen that all the segments might be 
taken into consideration. To avoid this, segments to be considered and set, are 
explicitly mentioned here.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to