hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Min Zhou <coderp...@gmail.com>
Subject Re: thread cofinement session state
Date Tue, 10 Mar 2009 03:28:05 GMT
On Tue, Mar 10, 2009 at 11:23 AM, Prasad Chakka <prasad@facebook.com> wrote:

>   TThreadPoolServer is supposed to use a new thread for each connection.
>

Exactly! But I dont think it will construct a new session state for the new
thread,  for new connection in other words.



>
>
> ------------------------------
> *From: *Joydeep Sen Sarma <jssarma@facebook.com>
> *Reply-To: *<hive-user@hadoop.apache.org>
> *Date: *Mon, 9 Mar 2009 20:16:22 -0700
> *To: *<hive-user@hadoop.apache.org>
> *Subject: *RE: thread cofinement session state
>
> (also been reading up on this code a bit just now)
>
> That’s weird. It seems to be using TThreadPoolServer and that seems to just
> service all requests from a single connection in one thread. (and uses the
> same processor I assume that seems to initialize the session state in the
> interface constructor)
>
> Are ur execute calls happening on the same connection?
>
> ------------------------------
>
> *From:* Min Zhou [mailto:coderplay@gmail.com <coderplay@gmail.com>]
> *Sent:* Monday, March 09, 2009 8:03 PM
> *To:* hive-user@hadoop.apache.org
> *Subject:* thread cofinement session state
>
> Hi list,
>    I found each invoke of HiveServer's execute method run in different
> threads. Those threads which execute a HSQL query(not a client connection
> may execute several pieces of queries), have not their own session state.
> when I call SessionState.get(), it will return null beacuse session state on
> this thread hadnot been constructed before. see also fragment of
> ExecDriver.java:
>
>   public static String getRealFiles(Configuration conf) {
>     // fill in local files to be added to the task environment
>     SessionState ss = SessionState.get();  // return ss will get null !!!
>    ...
>   }
>
> Is it a bug?
>
> Thanks,
> Min
> --
> My research interests are distributed systems, parallel computing and
> bytecode based virtual machine.
>
> http://coderplay.javaeye.com
>
>

Min
-- 
My research interests are distributed systems, parallel computing and
bytecode based virtual machine.

http://coderplay.javaeye.com

Mime
View raw message