Flume Flume Flume Flume Source Flume Sink Flume

  • Slides: 88
Download presentation

Flume配置深入 • • Flume部署种类 Flume流配置 Flume Source Flume Sink Flume Channel Flume Interceptor Flume拓扑分析

Flume配置深入 • • Flume部署种类 Flume流配置 Flume Source Flume Sink Flume Channel Flume Interceptor Flume拓扑分析

Flume 流配置-配置多代理流程 这里我们连接从weblog-agent的avro-forward-sink 到 hdfs-agent的avro-collection-source收集源。最终结果从 外部源的appserver最终存储在HDFS的事件。

Flume 流配置-配置多代理流程 这里我们连接从weblog-agent的avro-forward-sink 到 hdfs-agent的avro-collection-source收集源。最终结果从 外部源的appserver最终存储在HDFS的事件。

Flume Source • Avro Source

Flume Source • Avro Source

Flume Source • Thrift Source

Flume Source • Thrift Source

Flume Source • Exec Source

Flume Source • Exec Source

Flume Source • JMS Source

Flume Source • JMS Source

Flume Source • JMS Source

Flume Source • JMS Source

Flume Source • Net. Cat Source

Flume Source • Net. Cat Source

Flume Source • Spooling Directory Source

Flume Source • Spooling Directory Source

Flume Source • Syslog Sources 读取syslog数据,并生成Flume event。 UDP Source将整个消息作为一个单一的event。 TCP Source 为每一个用回车( n)来分隔的字符串创建一个新的事件。 Ø

Flume Source • Syslog Sources 读取syslog数据,并生成Flume event。 UDP Source将整个消息作为一个单一的event。 TCP Source 为每一个用回车( n)来分隔的字符串创建一个新的事件。 Ø Syslog TCP Source Ø Multiport Syslog TCP Source Ø Syslog UDP Source

Flume Source Ø Syslog TCP Source

Flume Source Ø Syslog TCP Source

Flume Source Ø Multiport Syslog TCP Source

Flume Source Ø Multiport Syslog TCP Source

Flume Source Ø Multiport Syslog TCP Source

Flume Source Ø Multiport Syslog TCP Source

Flume Source Ø Syslog UDP Source

Flume Source Ø Syslog UDP Source

Flume Source • HTTP Source 一个Source接受flume event通过HTTP POST和 GET。 GET应只用于实验。Flume event 使用一个可插 拔的“handler”程序来实现转换,它必须实现的 HTTPSource.

Flume Source • HTTP Source 一个Source接受flume event通过HTTP POST和 GET。 GET应只用于实验。Flume event 使用一个可插 拔的“handler”程序来实现转换,它必须实现的 HTTPSource. Handler接口。此处理程序需要一个 Http. Servlet. Request和返回一个flume event列表。

Flume Source • HTTP Source

Flume Source • HTTP Source

Flume Source • Custom Source 一个Custom Source其实是对Source接口的实现。当 我们开始flume agent的时候必须将Custom Source和相依 赖的jar放到agent的classpath下面。Custom Source的 type就是我们实现Source接口对应的类全路径。

Flume Source • Custom Source 一个Custom Source其实是对Source接口的实现。当 我们开始flume agent的时候必须将Custom Source和相依 赖的jar放到agent的classpath下面。Custom Source的 type就是我们实现Source接口对应的类全路径。

Flume Sink • HDFS Sink

Flume Sink • HDFS Sink

Flume Sink • HDFS Sink

Flume Sink • HDFS Sink

Flume Sink • IRC Sink 从通道中取得信息到IRC Server。

Flume Sink • IRC Sink 从通道中取得信息到IRC Server。

Flume Sink • Hbase Sink

Flume Sink • Hbase Sink

Flume Sink • Hbase Sink

Flume Sink • Hbase Sink

Flume Sink • Async. Hbase Sink

Flume Sink • Async. Hbase Sink

Flume Channel • 通道是一个仓库,事件存储在上面。源通过通道添加事件, 接收器通过通道取事件。 Ø Memory Channel Ø JDBC Channel Ø File Channel

Flume Channel • 通道是一个仓库,事件存储在上面。源通过通道添加事件, 接收器通过通道取事件。 Ø Memory Channel Ø JDBC Channel Ø File Channel Ø Pseudo Transaction Channel Ø Custom Channel

Flume Channel • Memory Channel

Flume Channel • Memory Channel

Flume Channel • File Channel

Flume Channel • File Channel

Flume Channel • Pseudo Transaction Channel 备注: 仅仅用来测试目的,不是在生产环境中使用。

Flume Channel • Pseudo Transaction Channel 备注: 仅仅用来测试目的,不是在生产环境中使用。

Flume Channel • Custom Channel是对channel接口的实现。需要在 classpath中引入实现类和相关的jar文件。这Channel对应的 type是该类的完整路径。

Flume Channel • Custom Channel是对channel接口的实现。需要在 classpath中引入实现类和相关的jar文件。这Channel对应的 type是该类的完整路径。

Flume Channel Selectors • Replicating Channel Selector (default)

Flume Channel Selectors • Replicating Channel Selector (default)

Flume Channel Selectors • Multiplexing Channel Selector

Flume Channel Selectors • Multiplexing Channel Selector

Flume Channel Selectors • Custom Channel Selector 实现Channel. Selector 接口。

Flume Channel Selectors • Custom Channel Selector 实现Channel. Selector 接口。

Flume Sink Processors • Default Sink Processor 接收单一的Sink,不强制用户 为Sink创建Processor。

Flume Sink Processors • Default Sink Processor 接收单一的Sink,不强制用户 为Sink创建Processor。

Flume Sink Processors • Failover Sink Processor

Flume Sink Processors • Failover Sink Processor

Flume Sink Processors • Load balancing Sink Processor

Flume Sink Processors • Load balancing Sink Processor

Flume Event Serializers • file_roll sink 和hdfs sink 都支持Event. Serializer 接口。 Ø Body Text

Flume Event Serializers • file_roll sink 和hdfs sink 都支持Event. Serializer 接口。 Ø Body Text Serializer Ø Avro Event Serializer

Flume Event Serializers • Avro Text Serializer 别名:avro_event。这个拦截器将把事件序列化到一 个Avro容器文件中。使用的模式和RPC Avro机制使用到 的处理flume事件的机制一样。 这个序列化器继承自 Abstract. Avro.

Flume Event Serializers • Avro Text Serializer 别名:avro_event。这个拦截器将把事件序列化到一 个Avro容器文件中。使用的模式和RPC Avro机制使用到 的处理flume事件的机制一样。 这个序列化器继承自 Abstract. Avro. Event. Serializer类。

Flume Interceptors • Timestamp Interceptor 该拦截器可以往event的header中插入关键词为 timestamp的时间戳。

Flume Interceptors • Timestamp Interceptor 该拦截器可以往event的header中插入关键词为 timestamp的时间戳。

Flume Interceptors • Static Interceptor 该拦截器允许用户增加一个static 的header并为所有 的事件赋值。

Flume Interceptors • Static Interceptor 该拦截器允许用户增加一个static 的header并为所有 的事件赋值。