• Hadoop实战-Flume之Source multiplexing(十五)


    a1.sources = r1
    a1.sinks = k1 k2
    a1.channels = c1 c2
    
    # Describe/configure the source
    a1.sources.r1.type = netcat
    a1.sources.r1.bind = localhost
    a1.sources.r1.port = 44444
    
    # Describe the sink
    a1.sinks.k1.type =file_roll
    a1.sinks.k1.sink.directory=/home/chenyun/data/flume/file_sinke1
    
    a1.sinks.k2.type =file_roll
    a1.sinks.k2.sink.directory=/home/chenyun/data/flume/file_sinke2
    
    # Use a channel which buffers events in memory
    a1.channels.c1.type = memory
    a1.channels.c1.capacity = 1000
    a1.channels.c1.transactionCapacity = 100
    
    a1.channels.c2.type = memory
    a1.channels.c2.capacity = 1000
    a1.channels.c2.transactionCapacity = 100
    
    # Bind the source and sink to the channel
    a1.sources.r1.channels = c1 c2
    a1.sources.r1.interceptors = i1
    a1.sources.r1.interceptors.i1.type = regex_extractor 
    a1.sources.r1.interceptors.i1.regex = (\w+):(\w+):(\w+)
    a1.sources.r1.interceptors.i1.serializers = s1 s2 s3
    a1.sources.r1.interceptors.i1.serializers.s1.name = one
    a1.sources.r1.interceptors.i1.serializers.s2.name = two
    a1.sources.r1.interceptors.i1.serializers.s3.name = three
    a1.sources.r1.selector.type = multiplexing
    a1.sources.r1.selector.header = one
    a1.sources.r1.selector.mapping.hadoop = c1
    a1.sources.r1.selector.default = c2
    a1.sinks.k1.channel=c1
    a1.sinks.k2.channel = c2
  • 相关阅读:
    初学Android: 四大组件之Activity
    jQuery Pagination Plugin ajax分页控件
    PHPExcel 多工作表 导入
    PHPExcel 多工作表 导出
    js常用方法
    如何让多个不同版本的jquery库共存
    总结机器学习部分计算原理—续
    第四周学习进度报告
    总结机器学习部分计算原理
    数据清洗报告
  • 原文地址:https://www.cnblogs.com/qq27271609/p/6864169.html
Copyright © 2020-2023  润新知