-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflume-flatfile_agent (1).conf
44 lines (32 loc) · 1.67 KB
/
flume-flatfile_agent (1).conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# Agent "flatfile_agent" is to bring files from particular directory into HDFS directory Starts here
# Define Source, Channel & Sink
flatfile_agent.sources = splDirSrc
flatfile_agent.channels = memoryChannel
flatfile_agent.sinks = hdfsSink
# Configuring the souce
flatfile_agent.sources.splDirSrc.type = spooldir
flatfile_agent.sources.splDirSrc.spoolDir = /home/cloudera/sourcedata
# Configuring the channel
flatfile_agent.channels.memoryChannel.type = memory
flatfile_agent.channels.memoryChannel.capacity = 1000
flatfile_agent.channels.memoryChannel.transactionCapacity = 1000
flatfile_agent.sources.splDirSrc.fileHeader = false
# Configuring the Sink
flatfile_agent.sinks.hdfsSink.type = hdfs
flatfile_agent.sinks.hdfsSink.hdfs.path = /user/pmargu/flume_flatfiles/%Y_%m_%d_%H_%M
flatfile_agent.sinks.hdfsSink.hdfs.round = true
flatfile_agent.sinks.hdfsSink.hdfs.roundValue = 1
flatfile_agent.sinks.hdfsSink.hdfs.roundUnit = hour
flatfile_agent.sinks.hdfsSink.hdfs.useLocalTimeStamp = true
#flatfile_agent.sinks.hdfsSink.hdfs.path = /user/training/rana
flatfile_agent.sinks.hdfsSink.hdfs.fileType = DataStream
# Write format can be text or writable
flatfile_agent.sinks.hdfsSink.hdfs.writeFormat = Text
flatfile_agent.sinks.hdfsSink.hdfs.batchSize = 100
# Rollover file based on maximum size
flatfile_agent.sinks.hdfsSink.hdfs.rollSize = 0
# Never rollover based on the number of events
flatfile_agent.sinks.hdfsSink.hdfs.rollCount = 0
flatfile_agent.sources.splDirSrc.channels = memoryChannel
flatfile_agent.sinks.hdfsSink.channel = memoryChannel
# Agent "flatfile_agent" is to bring files from particular directory into HDFS directory Ends here