Github user kumarvishal09 commented on a diff in the pull request: https://github.com/apache/carbondata/pull/2622#discussion_r208865599 --- Diff: integration/spark-common/src/main/scala/org/apache/carbondata/spark/rdd/CarbonScanRDD.scala --- @@ -463,9 +463,10 @@ class CarbonScanRDD[T: ClassTag]( model.setStatisticsRecorder(recorder) // TODO: rewrite this logic to call free memory in FailureListener on failures. On success, - // no memory leak should be there, resources should be freed on success completion. - val listeners = CarbonReflectionUtils.getField("onCompleteCallbacks", context) + // TODO: no memory leak should be there, resources should be freed on success completion. + val listeners = CarbonReflectionUtils.getField("onCompleteCallbacks", context).get(context) --- End diff -- ok
---