Github user nitin2goyal commented on the pull request:

    https://github.com/apache/spark/pull/5880#issuecomment-107884711
  
    @chenghao-intel I get that. So, should we do something like :-
    
    lazy val cachedHiveConf = new HiveConf()
    
    private[this] def hiveConf(): HiveConf = {
        val ss = SessionState.get() // SessionState is lazy initializaion, it 
can be null here
        if (ss == null) {
          cachedHiveConf
        } else {
          ss.getConf
        }
      }


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to