Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Flume, mail # user - Flume and PollableSource.


Copy link to this message
-
Re: Flume and PollableSource.
Israel Ekpo 2013-09-24, 03:13
JMSSource, SequenceGeneratorSource and StressSource are all examples of
PollableSource implementations.

Take a look at the source code and you can get some ideas from there

http://flume.apache.org/releases/content/1.4.0/apidocs/org/apache/flume/source/jms/JMSSource.html

http://flume.apache.org/releases/content/1.4.0/apidocs/org/apache/flume/source/SequenceGeneratorSource.html

https://git-wip-us.apache.org/repos/asf?p=flume.git;a=blob_plain;f=flume-ng-sources/flume-jms-source/src/main/java/org/apache/flume/source/jms/JMSSource.java;hb=trunk

*Author and Instructor for the Upcoming Book and Lecture Series*
*Massive Log Data Aggregation, Processing, Searching and Visualization with
Open Source Software*
*http://massivelogdata.com*
On Tue, Sep 17, 2013 at 6:37 AM, Guillermo Ortiz <[EMAIL PROTECTED]>wrote:

> Thank you!,
>
> I have another question, I have checked and take a look to the code, how
> could I reimplement the code?? Because, It looks like I can't change the
> values of each recalled independent when it got result or not. could it
> that possible?
>
> Guillermo.
>
>
> 2013/9/16 Hari Shreedharan <[EMAIL PROTECTED]>
>
>>  You don't need to do anything with the PollableSourceRunner. Once you
>> create your PollableSource, drop it into Flume's classpath and configure it
>> as required and associate it with an active channel. Once that is done,
>> Flume will create a PollableSourceRunner instance to run your
>> PollableSource, and run it (it will sit in a loop and call your class's
>> process method).
>>
>>
>> Thanks,
>> Hari
>>
>> On Monday, September 16, 2013 at 7:40 AM, Guillermo Ortiz wrote:
>>
>> Hello,
>>
>> I'm working with Flume and I have a doubt, I want to create a PollSource
>> and go to look for the data time to time.
>>
>> I have create a class which implement PollableSource:
>>
>> *public class PullHttps extends AbstractSource implements PollableSource,
>> *
>> *        Configurable {*
>> *
>> *
>> But, I don't know how I should create the loop,,, who is who calls my
>> Source?? I have been reading the documentation and I have found the class
>> *PollableSourceRunner * but, I don't know if I should use that class and
>> I haven't gotten to advanced on that way.
>>
>> How do I have to use a PollableSource??
>>
>> Thank you.
>>
>>
>>
>