aurora-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dmitriy Shirchenko <cald...@gmail.com>
Subject Re: Review Request 45506: Execute shell-based health checks as the task user.
Date Thu, 31 Mar 2016 16:20:45 GMT

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




src/main/python/apache/aurora/common/health_check/shell.py (line 34)
<https://reviews.apache.org/r/45506/#comment189279>

    document inside docstring, plz.



src/main/python/apache/aurora/common/health_check/shell.py (line 56)
<https://reviews.apache.org/r/45506/#comment189291>

    why did you get rid of .format? i personally find it much clearer to understand so would
you please justify this decision.
    
    some refs:
    http://stackoverflow.com/a/5082482
    talk of deprecating % altogether in python3 and explicit mention for using .format.
    https://docs.python.org/3/whatsnew/2.6.html#pep-3101



src/main/python/apache/aurora/common/health_check/shell.py (line 61)
<https://reviews.apache.org/r/45506/#comment189293>

    why are you doing a separate try/except with timeout when subprocess.Popen already supports
it.
    
    you can still do a kill if that's your intention in one swoop.



src/main/python/apache/aurora/common/health_check/shell.py (line 69)
<https://reviews.apache.org/r/45506/#comment189295>

    :nit .format instead of interpolation.



src/test/python/apache/aurora/common/health_check/test_shell.py (line 24)
<https://reviews.apache.org/r/45506/#comment189277>

    damn, my bad. thanks for catching this!


- Dmitriy Shirchenko


On March 30, 2016, 11:41 p.m., Bill Farner wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45506/
> -----------------------------------------------------------
> 
> (Updated March 30, 2016, 11:41 p.m.)
> 
> 
> Review request for Aurora, Dmitriy Shirchenko and Zameer Manji.
> 
> 
> Bugs: AURORA-1641
>     https://issues.apache.org/jira/browse/AURORA-1641
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Here's a stab at this using `os` and `pwd` modules directly to demote health checks to
the target user.
> 
> 
> Diffs
> -----
> 
>   src/main/python/apache/aurora/common/health_check/shell.py 6cb7dfc164f4e16143fc974d50c19a5887d32015

>   src/main/python/apache/aurora/executor/common/health_checker.py 28fd3ec3ef7d0b66621c0295804af0eb72c64b4a

>   src/test/python/apache/aurora/common/health_check/test_shell.py 7026af8c4671a40f4b517ecf12149eac34a552c8

>   src/test/python/apache/aurora/executor/common/test_health_checker.py 19c4f76347e34374c29974c182d1f4c118bcb18d

> 
> Diff: https://reviews.apache.org/r/45506/diff/
> 
> 
> Testing
> -------
> 
> I haven't spent any time thinking of a test strategy for this, but i don't think we should
proceed without end-to-end validation.  I'm open to ideas here.
> 
> 
> Thanks,
> 
> Bill Farner
> 
>


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