Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
HBase >> mail # user >> slow operation in postPut


Copy link to this message
-
Re: slow operation in postPut
If I want to use multi-thread with thread safe, which class should I use?
On Thu, Aug 1, 2013 at 3:08 PM, Ted Yu <[EMAIL PROTECTED]> wrote:

> HTable is not thread safe.
>
> On Aug 1, 2013, at 5:58 AM, Pavel Hančar <[EMAIL PROTECTED]> wrote:
>
> > Hello,
> > I have a class extending BaseRegionObserver and I use the postPut method
> to
> > run a slow procedure. I'd like to run more these procedures in more
> > threads. Is it possible to run more HTable.put(put) methods
> concurrently? I
> > tried, but I have this error for each thread:
> >
> > Exception in thread "Thread-3" java.lang.IndexOutOfBoundsException:
> Index:
> > 1, Size: 1
> >        at java.util.ArrayList.rangeCheck(ArrayList.java:604)
> >        at java.util.ArrayList.remove(ArrayList.java:445)
> >        at
> > org.apache.hadoop.hbase.client.HTable.flushCommits(HTable.java:966)
> >        at org.apache.hadoop.hbase.client.HTable.doPut(HTable.java:811)
> >        at org.apache.hadoop.hbase.client.HTable.put(HTable.java:786)
> >        at img.PutFilesThread.run(PutFilesThread.java:74)
> >        at java.lang.Thread.run(Thread.java:724)
> >
> > Anybody has an idea?
> >  Thanks,
> >  Pavel Hančar
>
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB