phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Josh Elser (JIRA)" <>
Subject [jira] [Commented] (PHOENIX-4685) Parallel writes continuously to indexed table failing with OOME very quickly in 5.x branch
Date Wed, 11 Apr 2018 17:09:00 GMT


Josh Elser commented on PHOENIX-4685:

{quote} * the whole purpose of using CoprocessorHConnectionTableFactory is to build the connection
with custom configuration. if we use the shared connection then our index configuration will
not take effect like our ServerRpcController , threads etc . see HBASE-18359 and PHOENIX-3994.{quote}
This seems really important to me. That's a good catch, Ankit.
{quote} * default value of 256 for "hbase.hconnection.threads.max" may be less for all index
writers on the regionserver but in general scenario 8 threads per core(with common 32 core
server) should be sufficient but not sure such limit result in any regression from previous
versions or require documentation change.{quote}
Makes me wonder about how we can evaluate whether this is a problem in the future. It would
be neat if we could track hconnection thread saturation via Phoenix (along with the other
2ndary index metrics we added recently). I'm not sure how difficult that would be...
{quote}So , how about creating our own ShortCircuitConnection from the environment with custom
config and pool , and shared the same across all region while writing?
Make sure I'm understanding this correctly: we'd create+cache our own HConnection from the
CPEnv, with custom Phoenix properties to control the resources on that HConn? I like that
– avoids us causing other HBase problems trying to tweak Phoenix things.

> Parallel writes continuously to indexed table failing with OOME very quickly in 5.x branch
> ------------------------------------------------------------------------------------------
>                 Key: PHOENIX-4685
>                 URL:
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Rajeshbabu Chintaguntla
>            Assignee: Rajeshbabu Chintaguntla
>            Priority: Major
>             Fix For: 5.0.0
>         Attachments: PHOENIX-4685.patch, PHOENIX-4685_jstack
> Currently trying to write data to indexed table failing with OOME where unable to create
native threads. But it's working fine with 4.7.x branches. Found many threads created for
meta lookup and shared threads and no space to create threads. This is happening even with
short circuit writes enabled.
> {noformat}
> 2018-04-08 13:06:04,747 WARN  [RpcServer.default.FPBQ.Fifo.handler=9,queue=0,port=16020]
index.PhoenixIndexFailurePolicy: handleFailure failed
> java.lang.reflect.UndeclaredThrowableException
>         at
>         at org.apache.phoenix.index.PhoenixIndexFailurePolicy.handleFailureWithExceptions(
>         at org.apache.phoenix.index.PhoenixIndexFailurePolicy.handleFailure(
>         at org.apache.phoenix.hbase.index.write.IndexWriter.writeAndKillYourselfOnFailure(
>         at org.apache.phoenix.hbase.index.write.IndexWriter.writeAndKillYourselfOnFailure(
>         at org.apache.phoenix.hbase.index.Indexer.doPostWithExceptions(
>         at org.apache.phoenix.hbase.index.Indexer.doPost(
>         at org.apache.phoenix.hbase.index.Indexer.postBatchMutateIndispensably(
>         at org.apache.hadoop.hbase.regionserver.RegionCoprocessorHost$
>         at org.apache.hadoop.hbase.regionserver.RegionCoprocessorHost$
>         at org.apache.hadoop.hbase.coprocessor.CoprocessorHost$ObserverOperationWithoutResult.callObserver(
>         at org.apache.hadoop.hbase.coprocessor.CoprocessorHost.execOperation(
>         at org.apache.hadoop.hbase.regionserver.RegionCoprocessorHost.postBatchMutateIndispensably(
>         at org.apache.hadoop.hbase.regionserver.HRegion$MutationBatchOperation.doPostOpCleanupForMiniBatch(
>         at org.apache.hadoop.hbase.regionserver.HRegion.doMiniBatchMutate(
>         at org.apache.hadoop.hbase.regionserver.HRegion.batchMutate(
>         at org.apache.hadoop.hbase.regionserver.HRegion.batchMutate(
>         at org.apache.hadoop.hbase.regionserver.RSRpcServices.doBatchOp(
>         at org.apache.hadoop.hbase.regionserver.RSRpcServices.doNonAtomicBatchOp(
>         at org.apache.hadoop.hbase.regionserver.RSRpcServices.doNonAtomicRegionMutation(
>         at org.apache.hadoop.hbase.regionserver.RSRpcServices.multi(
>         at org.apache.hadoop.hbase.shaded.protobuf.generated.ClientProtos$ClientService$2.callBlockingMethod(
>         at
>         at
>         at org.apache.hadoop.hbase.ipc.RpcExecutor$
>         at org.apache.hadoop.hbase.ipc.RpcExecutor$
> Caused by: java.lang.reflect.UndeclaredThrowableException
>         at
>         at
>         at
>         at sun.reflect.GeneratedMethodAccessor28.invoke(Unknown Source)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(
>         at java.lang.reflect.Method.invoke(
>         at
>         at
>          ... 25 more
> Caused by: java.lang.Exception: java.lang.OutOfMemoryError: unable to create new native
>         at org.apache.phoenix.index.PhoenixIndexFailurePolicy$
>         at org.apache.phoenix.index.PhoenixIndexFailurePolicy$
>         at Method)
>         at
>         at
>         ... 32 more
> Caused by: java.lang.OutOfMemoryError: unable to create new native thread
>         at java.lang.Thread.start0(Native Method)
>         at java.lang.Thread.start(
>         at java.util.concurrent.ThreadPoolExecutor.addWorker(
>         at java.util.concurrent.ThreadPoolExecutor.execute(
>         at java.util.concurrent.AbstractExecutorService.submit(
>         at org.apache.hadoop.hbase.client.HTable.coprocessorService(
>         at org.apache.hadoop.hbase.client.HTable.coprocessorService(
>         at org.apache.phoenix.util.IndexUtil.updateIndexState(
>         at org.apache.phoenix.util.IndexUtil.updateIndexState(
>         at org.apache.phoenix.index.PhoenixIndexFailurePolicy$
>         ... 36 more
> {noformat}

This message was sent by Atlassian JIRA

View raw message