You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flume.apache.org by "Will McQueen (Issue Comment Edited) (JIRA)" <ji...@apache.org> on 2012/02/28 00:11:49 UTC

[jira] [Issue Comment Edited] (FLUME-1000) Properties validator misses an invalid config

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

Will McQueen edited comment on FLUME-1000 at 2/27/12 11:11 PM:
---------------------------------------------------------------

Thanks, Arvind. The javadocs for PropertiesFileConfigurationProvider say:
"For every <agent name> there must be three lists specified that include <agent name>.sources, <agent name>.sinks, and <agent name>.channels. Each of these lists must contain a space separated list of names corresponding to that particular entity."

I assumed this list must be non-empty, but that assumption was wrong.
                
      was (Author: will@cloudera.com):
    Thanks, Arvind. The javadocs for PropertiesFileConfigurationProvider say:
"For every <agent name> there must be three lists specified that include <agent name>.sources, <agent name>.sinks, and <agent name>.channels. Each of these lists must contain a space separated list of names corresponding to that particular entity."

I assumed this list must be non-empty, but that assumption was mostly wrong.
                  
> Properties validator misses an invalid config
> ---------------------------------------------
>
>                 Key: FLUME-1000
>                 URL: https://issues.apache.org/jira/browse/FLUME-1000
>             Project: Flume
>          Issue Type: Bug
>    Affects Versions: v1.1.0
>         Environment: RHEL 6.2 64-bit
>            Reporter: Will McQueen
>             Fix For: v1.1.0
>
>
> The following config is invalid, but is not caught by the properties validator (no sinks are specified). 
> a1.sources = r1
> a1.channels = c1
> #a1.sinks = k1
> a1.sources.r1.type = SEQ
> a1.sources.r1.channels = c1
> a1.channels.c1.type = MEMORY
> #a1.sinks.k1.type = logger
> #a1.sinks.k1.channel = c1
> If I run with this config, then the source and channel instance is created. If you add a print statement to ChannelProcessor.processEvent(), you'll see that the source is sending events to the channel. The source generates about 104 events, and then generates an additional one about every second... which is interesting, since the mem channel's default capacity is only 100 and there's no sink. When I do a runtime configuration by changing the the props file to this:
> #a1.sources = r1
> a1.channels = c1
> a1.sinks = k1
> #a1.sources.r1.type = SEQ
> #a1.sources.r1.channels = c1
> a1.channels.c1.type = MEMORY
> a1.sinks.k1.type = logger
> a1.sinks.k1.channel = c1
> ...then sink instance is created but the SEQ source is not stopped -- it continuously sends events at a rapid pace.
> I mention this because observing the behavior of even invalid configs might give clues as to problems that might occur with valid configs (such as a source not being stopped upon dynamic reconfig).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira