[ 
https://issues.apache.org/jira/browse/FLUME-2268?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13848297#comment-13848297
 ] 

Mike Percy commented on FLUME-2268:
-----------------------------------

Hi Udai, I am getting failing unit tests with this change. Did you try running 
the tests?

{noformat}
testRequestWithCompressionOnClientAndServerOnLevel6(org.apache.flume.sink.TestAvroSink)
  Time elapsed: 1 sec  <<< ERROR!
java.lang.IllegalStateException: Transaction Capacity of Memory Channel cannot 
be higher than the capacity.
        at 
com.google.common.base.Preconditions.checkState(Preconditions.java:145)
        at 
org.apache.flume.channel.MemoryChannel.configure(MemoryChannel.java:252)
        at org.apache.flume.conf.Configurables.configure(Configurables.java:41)
        at org.apache.flume.sink.TestAvroSink.setUp(TestAvroSink.java:112)
        at org.apache.flume.sink.TestAvroSink.doRequest(TestAvroSink.java:697)
        at 
org.apache.flume.sink.TestAvroSink.testRequestWithCompressionOnClientAndServerOnLevel6(TestAvroSink.java:685)
{noformat}

This brings up another issue that I hadn't considered. Looks like we have a 
check to ensure transactionCapacity <= capacity.

Either we need to remove that check, or we need to increase the default 
capacity of the memory channel.

Assuming we increase the memory channel default capacity, then @ 10,000 
capacity if each event is roughly 1KB then we will be using roughly 10MB of 
heap. Ashish brought up a good point that it would be a good idea to increase 
the default memory given to Flume in that case. I think that makes sense.

Alternatively, we could just remove the assertion that transactionCapacity <= 
capacity, which I don't really think is a necessary check. It's clean but not 
super practical.

For now, I'm withdrawing the +1 so we can figure out the details.

Offhand, I'm leaning towards removing the assertion. Anyone else have thoughts 
on this?

> Increase default transactionCapacity for MemoryChannel from 100 to 10000
> ------------------------------------------------------------------------
>
>                 Key: FLUME-2268
>                 URL: https://issues.apache.org/jira/browse/FLUME-2268
>             Project: Flume
>          Issue Type: Improvement
>          Components: Channel
>    Affects Versions: v1.4.0
>            Reporter: Udai Kiran Potluri
>            Assignee: Udai Kiran Potluri
>            Priority: Minor
>         Attachments: FLUME-2268-0.patch
>
>
> The current MemoryChannel default value is 100. Increasing it to 10000 would 
> be useful.



--
This message was sent by Atlassian JIRA
(v6.1.4#6159)

Reply via email to