Github user gvramana commented on a diff in the pull request:
https://github.com/apache/carbondata/pull/1508#discussion_r151407441
--- Diff:
integration/spark2/src/main/scala/org/apache/spark/sql/CarbonSession.scala ---
@@ -212,6 +212,18 @@ object CarbonSession {
ThreadLocalSessionInfo.setCarbonSessionInfo(currentThreadSessionInfo)
}
+ def threadUnset(key: String): Unit = {
+ var currentThreadSessionInfo =
ThreadLocalSessionInfo.getCarbonSessionInfo
+ if (currentThreadSessionInfo == null) {
--- End diff --
If null then not required to unset
---