[ 
https://issues.apache.org/jira/browse/FLUME-2706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ferenc Szabo updated FLUME-2706:
--------------------------------
    Fix Version/s:     (was: 1.8.0)
                   1.9.0

> Camel source
> ------------
>
>                 Key: FLUME-2706
>                 URL: https://issues.apache.org/jira/browse/FLUME-2706
>             Project: Flume
>          Issue Type: New Feature
>          Components: Sinks+Sources
>            Reporter: David Greco
>            Priority: Minor
>             Fix For: 1.9.0
>
>         Attachments: flume-2706.patch
>
>
> This component can start Camel routes, in this way provides a very powerful 
> mechanism for ingesting data from virtually any source supported by Camel 
> http://camel.apache.org.
> This source can be configured either with a Camel URI or with an XML file 
> containing route specifications.
> The configuration is very simple, let's show a couple of examples:
> 1. Configuration by an URI:
> tier1.sources = source1
> tier1.channels = channel1
> tier1.sinks  = sink1
> tier1.sources.source1.type = org.apache.flume.source.camel.CamelSource
> tier1.sources.source1.sourceURI  = 
> twitter://streaming/sample?type=event&consumerKey=<key>&consumerSecret=<secret>&accessToken=<accessToken>
> any URI supported by Camel components is valid. For Twitter, see 
> [here](http://camel.apache.org/twitter.html).
> 2. Configuration by an xml file:
> tier1.sources = source1
> tier1.channels  = channel1
> tier1.sinks = sink1
> tier1.sources.source1.type = org.apache.flume.source.camel.CamelSource
> tier1.sources.source1.routesFile = conf/routes.xml
> where the routes.xml can contain something like:
> <routes xmlns="http://camel.apache.org/schema/spring";>
>     <route id="route">
>         <from 
> uri="twitter://streaming/sample?type=event&amp;consumerKey=<key>&amp;consumerSecret=<secret>&amp;accessToken=<accessToken>"/>
>         <to uri="direct-vm://source1"/>
>     </route>
> </routes>
> any route that wants to send data to flume must have as a target endpoint an 
> URI with the following format: direct-vm://<name of the CamelSource>, so in 
> our case the CamelSource's name is source1 and consequently the endpoint URI 
> is: direct-vm://source1 as shown in the XML snippet above.
> The sourceURI property takes always precedence on the routesFile property.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to