> On Oct. 8, 2014, 4:28 p.m., Bill Farner wrote:
> > src/main/python/apache/aurora/common/transport.py, line 28
> > <https://reviews.apache.org/r/26424/diff/2/?file=714839#file714839line28>
> >
> >     I find it odd to extract a function for this.  If i were a newcomer, i 
> > would immediately inline this function for a 3->1 line code savings.
> >     
> >     If you feel strongly about extracting a function, a comment is needed 
> > to explain the thought process.
> 
> Joshua Cohen wrote:
>     My thought process was, "it's already weird for initializing the 
> transport to have a side effect of globally changing the log level for 
> requests, this way if something needs to change requests logging without 
> instantiating a transport, they could just invoke this function."
>     
>     Does that sound reasonable enough to keep the function? If so, I can add 
> a comment, if not I can inline.

To me, the otherwise-unused function only adds to the weirdness of it all :-)

I say YAGNI - inline, add a comment that we don't like doing this, but want 
quiet output.

Side note: is there no other wsy to do this?  It's surprising that this ia a 
global setting in the library.


- Bill


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


On Oct. 7, 2014, 8:32 p.m., Joshua Cohen wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/26424/
> -----------------------------------------------------------
> 
> (Updated Oct. 7, 2014, 8:32 p.m.)
> 
> 
> Review request for Aurora, Joe Smith and Bill Farner.
> 
> 
> Bugs: AURORA-770
>     https://issues.apache.org/jira/browse/AURORA-770
> 
> 
> Repository: aurora
> 
> 
> Description
> -------
> 
> Disable requests http connection logging.
> 
> 
> Diffs
> -----
> 
>   src/main/python/apache/aurora/common/transport.py 
> 6f7c355d725b5e537cc4ae471170eaa8431da326 
>   src/test/python/apache/aurora/common/test_transport.py 
> c722eae2d04dec90e9c772f49c578184a2bdf76c 
> 
> Diff: https://reviews.apache.org/r/26424/diff/
> 
> 
> Testing
> -------
> 
> Added hokey test, ran hokey test.
> 
> Also verified the lack of http connection logs when running client commands 
> directly.
> 
> 
> Thanks,
> 
> Joshua Cohen
> 
>

Reply via email to