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

Hari Shreedharan commented on FLUME-1227:
-----------------------------------------

Hi Roshan,

Thanks for the updated design doc and patch. I looked at the design doc and 
this approach looks good. I like the fact that there are no dependencies (at 
least as mentioned in the doc) on the file channel's implicit behavior. I have 
on question though. The drain order queue seems to keep a count of how many 
events are written to which store each time a write happens (using the -ve and 
+ve numbers). It looks like channel can actually return fewer events than total 
available in the case where there are only "n" events in the primary queue and 
an "n+1"-th take would happen - since the events in a particular txn will 
always come from one queue. I think we should be able to pull events from the 
other store if it turns out to be required - else we expect the sink to come 
back and poll immediately - and also cause sink side transactions to be smaller 
than they have to be - which can cause Avro/HDFS batch sizes to be smaller than 
configured causing perf issues. 

Also, I am not clear on how the channel recovers from an "overflow" situation. 
Assume that the primary has capacity of "n" and we are currently overflowing. 
When do we decide to go back to the primary? Is it when all "n" from the 
primary have been removed, or we don't go back to it until restart (sorry I 
didn't look at the code yet - this does not seem to have gotten a mention in 
the design doc).


                
> Introduce some sort of SpillableChannel
> ---------------------------------------
>
>                 Key: FLUME-1227
>                 URL: https://issues.apache.org/jira/browse/FLUME-1227
>             Project: Flume
>          Issue Type: New Feature
>          Components: Channel
>            Reporter: Jarek Jarcec Cecho
>            Assignee: Roshan Naik
>         Attachments: 1227.patch.1, FLUME-1227.v2.patch, SpillableMemory 
> Channel Design 2.pdf, SpillableMemory Channel Design.pdf
>
>
> I would like to introduce new channel that would behave similarly as scribe 
> (https://github.com/facebook/scribe). It would be something between memory 
> and file channel. Input events would be saved directly to the memory (only) 
> and would be served from there. In case that the memory would be full, we 
> would outsource the events to file.
> Let me describe the use case behind this request. We have plenty of frontend 
> servers that are generating events. We want to send all events to just 
> limited number of machines from where we would send the data to HDFS (some 
> sort of staging layer). Reason for this second layer is our need to decouple 
> event aggregation and front end code to separate machines. Using memory 
> channel is fully sufficient as we can survive lost of some portion of the 
> events. However in order to sustain maintenance windows or networking issues 
> we would have to end up with a lot of memory assigned to those "staging" 
> machines. Referenced "scribe" is dealing with this problem by implementing 
> following logic - events are saved in memory similarly as our MemoryChannel. 
> However in case that the memory gets full (because of maintenance, networking 
> issues, ...) it will spill data to disk where they will be sitting until 
> everything start working again.
> I would like to introduce channel that would implement similar logic. It's 
> durability guarantees would be same as MemoryChannel - in case that someone 
> would remove power cord, this channel would lose data. Based on the 
> discussion in FLUME-1201, I would propose to have the implementation 
> completely independent on any other channel internal code.
> Jarcec

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to