# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not use this file except in compliance # with the License. You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # # # Flume Configuration # This file contains configuration for one Agent identified as host1. # This file also contains invalid configuration for few agents # host2, host3 etc. # host1.sources = avroSource syslogSource host1.channels = jdbcChannel memChannel host1.sinks = hdfsSink # avroSource configuration host1.sources.avroSource.type = avro host1.sources.avroSource.bind = 127.0.0.1 host1.sources.avroSource.port = 11001 host1.sources.avroSource.channels = jdbcChannel # syslogSource configuration host1.sources.syslogSource.type = syslogtcp host1.sources.syslogSource.port = 13231 host1.sources.syslogSource.channels = jdbcChannel memChannel host1.sources.syslogSource.selector.type = multiplexing host1.sources.syslogSource.selector.header = my.selector.header host1.sources.syslogSource.selector.mapping.all = jdbcChannel memChannel host1.sources.syslogSource.selector.mapping.persist = jdbcChannel host1.sources.syslogSource.selector.default = memChannel # jdbcChannel configuration host1.channels.jdbcChannel.type = jdbc host1.channels.jdbcChannel.jdbc.driver = com.mysql.jdbc.Driver host1.channels.jdbcChannel.jdbc.connect.url = http://localhost/flumedb host1.channels.jdbcChannel.jdbc.username = flume host1.channels.jdbcChannel.jdbc.password = flume # memChannel configuration host1.channels.memChannel.type = memory host1.channels.memChannel.capacity = 10000 # hdfsSink configuration host1.sinks.hdfsSink.type = hdfs host1.sinks.hdfsSink.namenode = hdfs://localhost/ host1.sinks.hdfsSink.batchsize = 1000 host1.sinks.hdfsSink.runner.type = polling host1.sinks.hdfsSink.runner.polling.interval = 60 # # Agent configuration for host2 - invalid because channels is not # defined. # host2.sources = src1 host2.sinks = sink1 host2.sources.src1.type = foo host2.sources.src1.runner = xxx host2.sources.src1.runner.type = ttt host2.sinks.sink1.type = bar host2.sinks.sink1.runner = yyy host2.sinks.sink1.runner.type = yyy # # Agent configuration for host3 - invalid because the effective set of # channels is 0 since configured ones are not active, and active ones are # not configured. # host3.sources = src1 src2 host3.channels = ch1 ch2 host3.sources.src1.type = foo host3.sources.src1.runner.type = x host3.sources.src1.channels = ch1 ch3 host3.channels.ch2.foo = bar host3.channels.ch3.type = foo host3.channels.ch3.xxx = yyy # # Agent configuration for host4 - invalid, same as host3 except that this # time one channel configuration is valid but no sources or sinks are # configured correctly. # host4.sources = src2 host4.channels = ch1 ch2 host4.sources.src1.type = foo host4.sources.src1.runner.type = x host4.sources.src1.channels = ch1 ch2 host4.channels.ch2.foo = bar host4.channels.ch2.type = abc host4.channels.ch3.type = foo host4.channels.ch3.xxx = yyy # # Agent configuration for host5 - valid using a sinkgroup with a failover processor # One of the sinks isn't properly configured but the group should let it fail and drop down # to two sinks # host5.sources = src1 host5.channels = ch1 host5.sinks = sink1 sink2 sink3 host5.sinkgroups = sg1 host5.channels.ch1.type = abc host5.sources.src1.type = def host5.sources.src1.channels = ch1 host5.sinks.sink1.type = foo host5.sinks.sink1.channel = ch1 host5.sinks.sink2.type = bar host5.sinks.sink2.channel = ch1 host5.sinkgroups.sg1.sinks = sink1 sink2 sink3 host5.sinkgroups.sg1.policy.type = failover host5.sinkgroups.sg1.policy.priority.sink1 = 1 host5.sinkgroups.sg1.policy.priority.sink2 = 2