You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Gopal V (JIRA)" <ji...@apache.org> on 2018/07/01 06:00:00 UTC

[jira] [Created] (HIVE-20043) HiveServer2: SessionState has a static sync block around an AtomicBoolean

Gopal V created HIVE-20043:
------------------------------

             Summary: HiveServer2: SessionState has a static sync block around an AtomicBoolean
                 Key: HIVE-20043
                 URL: https://issues.apache.org/jira/browse/HIVE-20043
             Project: Hive
          Issue Type: Bug
          Components: HiveServer2
    Affects Versions: 3.0.0
            Reporter: Gopal V


{code}
  private static void start(SessionState startSs, boolean isAsync, LogHelper console) {
...
    synchronized(SessionState.class) {
      if (!startSs.isStarted.compareAndSet(false, true)) {
        return;
      }
    }
{code}

startSs.isStarted is an AtomicBoolean, which makes it hard to know why this code is locked with a static lock.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)