ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sumit Mohanty" <smoha...@hortonworks.com>
Subject Re: Review Request 41006: AMBARI-14226 : AMS service check gives up after 1 try when AMS has just started up and HBase is not in proper state.
Date Sat, 05 Dec 2015 02:19:18 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/41006/#review109071
-----------------------------------------------------------

Ship it!


Ship It!

- Sumit Mohanty


On Dec. 5, 2015, 1:01 a.m., Aravindan Vijayan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41006/
> -----------------------------------------------------------
> 
> (Updated Dec. 5, 2015, 1:01 a.m.)
> 
> 
> Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
> 
> 
> Bugs: AMBARI-14226
>     https://issues.apache.org/jira/browse/AMBARI-14226
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> PROBLEM
> 
> AMS service check throws the following error and exits when AMS has just started up and
HBase is not in proper state.
> 
> Traceback (most recent call last):
> File "/var/lib/ambari-agent/cache/common-services/AMBARI_METRICS/0.1.0/package/scripts/service_check.py",
line 165, in <module>
> AMSServiceCheck().execute()
> File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py",
line 217, in execute
> method(env)
> File "/usr/lib/python2.6/site-packages/ambari_commons/os_family_impl.py", line 89, in
thunk
> return fn(*args, **kwargs)
> File "/var/lib/ambari-agent/cache/common-services/AMBARI_METRICS/0.1.0/package/scripts/service_check.py",
line 95, in service_check
> response = conn.getresponse()
> File "/usr/lib64/python2.7/httplib.py", line 1045, in getresponse
> response.begin()
> File "/usr/lib64/python2.7/httplib.py", line 409, in begin
> version, status, reason = self._read_status()
> File "/usr/lib64/python2.7/httplib.py", line 373, in _read_status
> raise BadStatusLine(line)
> httplib.BadStatusLine: ''
> 
> BUG
> In service_check.py, we make a call to conn.getresponse() after the "catch" block, thereby
making the assumption that the response is always OK at this step. But there are are rare
cases when conn.request() can be OK and conn.getresponse() gives out BadStatusException (subclass
of HttpException).
> 
> FIX
> Moving conn.getresponse() to a place before the exception catch block.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/common-services/AMBARI_METRICS/0.1.0/package/scripts/service_check.py
d2c0cbb 
> 
> Diff: https://reviews.apache.org/r/41006/diff/
> 
> 
> Testing
> -------
> 
> Manual Testing done. 
> 
> Python unit tests pass (3 failures are unrelated).
> 
> 
> Thanks,
> 
> Aravindan Vijayan
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message