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


Minor comment.


core/src/main/scala/kafka/server/AbstractFetcherThread.scala
<https://reviews.apache.org/r/33551/#comment132027>

    The way this function is implemented, it potentially acquires the same lock 
twice when it's not really necessary.
    
    Can you simply merge this check into the synchronized block above? It's a 
fairly cheap check I guess. The fetch request can still be performed outside 
the locked segment.


- Aditya Auradkar


On April 25, 2015, 2:48 p.m., Sriharsha Chintalapani wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/33551/
> -----------------------------------------------------------
> 
> (Updated April 25, 2015, 2:48 p.m.)
> 
> 
> Review request for kafka.
> 
> 
> Bugs: KAFKA-2150
>     https://issues.apache.org/jira/browse/KAFKA-2150
> 
> 
> Repository: kafka
> 
> 
> Description
> -------
> 
> KAFKA-2150. FetcherThread backoff need to grab lock before wait on condition.
> 
> 
> Diffs
> -----
> 
>   core/src/main/scala/kafka/server/AbstractFetcherThread.scala 
> a439046e118b6efcc3a5a9d9e8acb79f85e40398 
> 
> Diff: https://reviews.apache.org/r/33551/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Sriharsha Chintalapani
> 
>

Reply via email to