hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Szehon Ho (JIRA)" <>
Subject [jira] [Commented] (HIVE-14521) codahale metrics exceptions
Date Thu, 11 Aug 2016 22:02:21 GMT


Szehon Ho commented on HIVE-14521:

So there is a method 'SessionState.getPerfLogger().cleanupPerfLogMetrics();' that i introduced
in the driver return path for success or failure case that should take care of the error handling
in theory.

As per multi threading, the scopes are Thread local, but they are opened at []
and closed []
so i believe this should be on the same thread.

I did a search and noticed that the PerfLogger.COMPILE scope is also used in TezJobMonitor,
that might cause a conflict as its different thread.  Is it possible to rename that one?

> codahale metrics exceptions
> ---------------------------
>                 Key: HIVE-14521
>                 URL:
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Sergey Shelukhin
> One some random setup, I see bazillions of errors like this in HS2 log, Gb-s of logs
> {noformat}
> 2016-08-08 04:52:18,619 WARN  [HiveServer2-Handler-Pool: Thread-101]: log.PerfLogger
( - Error recording metrics
> Scope named is not closed, cannot be opened.
>         at org.apache.hadoop.hive.common.metrics.metrics2.CodahaleMetrics$
>         at org.apache.hadoop.hive.common.metrics.metrics2.CodahaleMetrics.startStoredScope(
>         at org.apache.hadoop.hive.ql.log.PerfLogger.beginMetrics(
>         at org.apache.hadoop.hive.ql.log.PerfLogger.PerfLogBegin(
>         at org.apache.hadoop.hive.ql.Driver.compile(
>         at org.apache.hadoop.hive.ql.Driver.compile(
>         at org.apache.hadoop.hive.ql.Driver.compileInternal(
>         at org.apache.hadoop.hive.ql.Driver.compileAndRespond(
>         at org.apache.hive.service.cli.operation.SQLOperation.prepare(
>         at org.apache.hive.service.cli.operation.SQLOperation.runInternal(
>         at
>         at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementInternal(
>         at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementAsync(
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(
> {noformat}
> I suspect that either, just like the metastore deadline, this needs better error handling
when whatever the metrics surround fails; or, it is just not thread safe.
> But I actually haven't looked at the code yet.

This message was sent by Atlassian JIRA

View raw message