org.apache.flume
Interface ChannelSelector

All Superinterfaces:
Configurable, NamedComponent
All Known Implementing Classes:
AbstractChannelSelector, MultiplexingChannelSelector, ReplicatingChannelSelector

public interface ChannelSelector
extends NamedComponent, Configurable

Allows the selection of a subset of channels from the given set based on its implementation policy. Different implementations of this interface embody different policies that affect the choice of channels that a source will push the incoming events to.


Method Summary
 List<Channel> getAllChannels()
           
 List<Channel> getOptionalChannels(Event event)
          Returns a list of optional channels.
 List<Channel> getRequiredChannels(Event event)
          Returns a list of required channels.
 void setChannels(List<Channel> channels)
           
 
Methods inherited from interface org.apache.flume.NamedComponent
getName, setName
 
Methods inherited from interface org.apache.flume.conf.Configurable
configure
 

Method Detail

setChannels

void setChannels(List<Channel> channels)
Parameters:
channels - all channels the selector could select from.

getRequiredChannels

List<Channel> getRequiredChannels(Event event)
Returns a list of required channels. A failure in writing the event to these channels must be communicated back to the source that received this event.

Parameters:
event -
Returns:
the list of required channels that this selector has selected for the given event.

getOptionalChannels

List<Channel> getOptionalChannels(Event event)
Returns a list of optional channels. A failure in writing the event to these channels must be ignored.

Parameters:
event -
Returns:
the list of optional channels that this selector has selected for the given event.

getAllChannels

List<Channel> getAllChannels()
Returns:
the list of all channels that this selector is configured to work with.


Copyright © 2009-2013 Apache Software Foundation. All Rights Reserved.