Flume Channel Selector

Source: Internet
Author: User

Flume based on channel selector can realize fan-in, fan-out.

The same data source is distributed to different purposes, such as.



The channel selector can be defined on source:

123456789 a1.sources=r1...a1.channels=c1 c2...a1.sources.r1.selector.type=multiplexinga1.sources.r1.selector.header=typea1.sources.r1.selector.mapping.type1=c1a1.sources.r1.selector.mapping.type2=c2...

But where does this type variable come from?

Workaround:

1. Modify the source code used for the source, apply to the client side, different data types to add different type

2, configure interceptor on the source side, set the variable type by interceptor on the header

Like what:

Use Regex_extractor, the data passed to the processing, extract the type value (if possible, you can add the type value in the client side of the data format, easy to use Regex_extractor extract ).

3, in the source side of the custom interceptor, in interceptor to the processing variable type







From for notes (Wiz)

Flume Channel Selector

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.