You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Ted Yu (JIRA)" <ji...@apache.org> on 2017/09/22 16:00:03 UTC

[jira] [Commented] (HBASE-18386) When the zookeeper host cannot be resolved, provide better error message

    [ https://issues.apache.org/jira/browse/HBASE-18386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16176623#comment-16176623 ] 

Ted Yu commented on HBASE-18386:
--------------------------------

{code}
  int zk_result = zoo_get(this->zk_, zk_node.c_str(), 0,
                          reinterpret_cast<char *>(buf->writableData()), &len, nullptr);
  if (zk_result != ZOK || len < 9) {
{code}
On top of checking return value, exception should be handled properly.

> When the zookeeper host cannot be resolved, provide better error message
> ------------------------------------------------------------------------
>
>                 Key: HBASE-18386
>                 URL: https://issues.apache.org/jira/browse/HBASE-18386
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: Ted Yu
>            Priority: Minor
>
> Currently, when the zookeeper host cannot be resolved, we would see:
> {code}
> 2017-07-15 19:42:09,367:3811(0x7f9ee2ffd700):ZOO_ERROR@getaddrs@613: getaddrinfo: No such file or directory
> *** Aborted at 1500147729 (unix time) try "date -d @1500147729" if you are using GNU date ***
> PC: @           0x6f4c28 zoo_get
> *** SIGSEGV (@0x260) received by PID 3811 (TID 0x7f9ee2ffd700) from PID 608; stack trace: ***
>     @     0x7f9eee0923d0 (unknown)
>     @           0x6f4c28 zoo_get
>     @           0x4444b4 hbase::LocationCache::ReadMetaLocation()
>     @           0x449ec4 std::_Function_handler<>::_M_invoke()
>     @           0x55ec12 wangle::ThreadPoolExecutor::runTask()
>     @           0x54dfca wangle::CPUThreadPoolExecutor::threadRun()
>     @           0x55f892 std::_Function_handler<>::_M_invoke()
> {code}
> There should be more intuitive error message so that user knows what to do next.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)