Re: Insert blocked

2012-07-24 Thread lars hofhansl
and holds references to a preexisting Connection and Threadpool... Very fast to create and collect. -- Lars - Original Message - From: Mohit Anchlia To: user@hbase.apache.org Cc: Sent: Tuesday, July 24, 2012 1:04 PM Subject: Re: Insert blocked On Tue, Jul 24, 2012 at 12:55 PM, Elliott

Re: Insert blocked

2012-07-24 Thread Mohit Anchlia
adoop-hbase.blogspot.com/2011/12/long-running-hbase-clients.html > > > > > > -- Lars > > > > > > > > - Original Message - > > From: Elliott Clark > > To: user@hbase.apache.org > > Cc: > > Sent: Monday, July 23, 2012 3:54 PM

Re: Insert blocked

2012-07-24 Thread Elliott Clark
Pool "monster". > > Also see here (if you don't mind the plug): > http://hadoop-hbase.blogspot.com/2011/12/long-running-hbase-clients.html > > > -- Lars > > > > - Original Message - > From: Elliott Clark > To: user@hbase.apache.org > Cc:

Re: Insert blocked

2012-07-24 Thread Mohit Anchlia
I removed the close call and it works. So it looks like close call should be called only at the end. But then how does the pool know that the object is available if it's not returned to the pool explicitly? On Tue, Jul 24, 2012 at 10:00 AM, Mohit Anchlia wrote: > > > On Tue, Jul 24, 2012 at 3:09

Re: Insert blocked

2012-07-24 Thread Mohit Anchlia
On Tue, Jul 24, 2012 at 3:09 AM, Lyska Anton wrote: > Hi, > > after first insert you are closing your table in finally block. thats why > thread hangs > I thought I need to close HTableInterface to return it back to the pool. Is that not the case? > > 24.07.2012 3:41, Mohit Anchlia пишет: > >>

Re: Insert blocked

2012-07-24 Thread Lyska Anton
Hi, after first insert you are closing your table in finally block. thats why thread hangs 24.07.2012 3:41, Mohit Anchlia пишет: I am now using HTablePool but still the call hangs at "put". My code is something like this: hTablePool = *new* HTablePool(config,*MAX_POOL_SIZE*); result = *new*

Re: Insert blocked

2012-07-23 Thread Asaf Mesika
Is htable in autoFlush? What's your client buffer size? What the thread stuck on? Take a thread dump Sent from my iPad On 24 ביול 2012, at 03:42, Mohit Anchlia wrote: > I am now using HTablePool but still the call hangs at "put". My code is > something like this: > > > hTablePool = *new* HTable

Re: Insert blocked

2012-07-23 Thread lars hofhansl
011/12/long-running-hbase-clients.html -- Lars - Original Message - From: Elliott Clark To: user@hbase.apache.org Cc: Sent: Monday, July 23, 2012 3:54 PM Subject: Re: Insert blocked HTable is not thread safe[1]. It's better to use HTablePool if you want to share things acros

Re: Insert blocked

2012-07-23 Thread Mohit Anchlia
I am now using HTablePool but still the call hangs at "put". My code is something like this: hTablePool = *new* HTablePool(config,*MAX_POOL_SIZE*); result = *new* SessionTimelineDAO(hTablePool.getTable(t.name()), ColumnFamily.*S_T_MTX*); public SessionTimelineDAO(HTableInterface hTableInterfac

Re: Insert blocked

2012-07-23 Thread Mohit Anchlia
On Mon, Jul 23, 2012 at 3:54 PM, Elliott Clark wrote: > HTable is not thread safe[1]. It's better to use HTablePool if you want to > share things across multiple threads.[2] > > 1 > http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/client/HTable.html > 2 > > http://hbase.apache.org/apidocs/o

Re: Insert blocked

2012-07-23 Thread Elliott Clark
HTable is not thread safe[1]. It's better to use HTablePool if you want to share things across multiple threads.[2] 1 http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/client/HTable.html 2 http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/client/HTablePool.html On Mon, Jul 23, 2012 at

Insert blocked

2012-07-23 Thread Mohit Anchlia
I am writing a stress tool to test my specific use case. In my current implementation HTable is a global static variable that I initialize just once and use it accross multiple threads. Is this ok? My row key consists of (timestamp - (timestamp % 1000)) and cols are counters. What I am seeing is t