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



flume-ng-core/src/main/java/org/apache/flume/channel/MemoryChannel.java
<https://reviews.apache.org/r/6982/#comment25766>

    Semaphores and synchronized/monitors are essentially different ways of 
achieving the same goal. 
    
    The only difference is that when you have permits > 1, semaphores are much 
better since each semaphore operation is atomic and you don't need to worry 
about handling thread context switches happening in between.
    
    Also in Java, traditionally java.util.concurrent.* classes have been 
implemented more efficiently than the language constructs themselves - though 
this seems to be fading over time, as synchornized/wait/notify have been 
getting better.


- Hari Shreedharan


On Sept. 16, 2012, 3:54 a.m., Ted Malaska wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/6982/
> -----------------------------------------------------------
> 
> (Updated Sept. 16, 2012, 3:54 a.m.)
> 
> 
> Review request for Flume.
> 
> 
> Description
> -------
> 
> 1. The user will be able to define a byteCapacity and a 
> byteCapacityBufferPercentage.
> 2. Events byte size will be estimated from there body contents
> 3. On put bytes are added to current total
> 4. On commit any uncommitted takes are removed from the current byte total
> 5. On rollover any uncommitted puts are removed from the current byte total
> 
> 
> This addresses bug FLUME-1535.
>     https://issues.apache.org/jira/browse/FLUME-1535
> 
> 
> Diffs
> -----
> 
>   flume-ng-core/src/main/java/org/apache/flume/channel/MemoryChannel.java 
> c72e97c 
>   flume-ng-core/src/test/java/org/apache/flume/channel/TestMemoryChannel.java 
> e070864 
> 
> Diff: https://reviews.apache.org/r/6982/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Ted Malaska
> 
>

Reply via email to