apache flume-时间戳不正确

pkln4tw6  于 2021-06-03  发布在  Hadoop
关注(0)|答案(1)|浏览(388)

当我使用apacheflume时,我得到一个毫秒时间戳,然后是第二个时间戳。这是我的flume conf文件:


# Name the components on this agent

a1.sources = r1
a1.sinks = k1
a1.channels = c1

# Describe/configure the source

a1.sources.r1.type = org.apache.flume.source.http.HTTPSource
a1.sources.r1.port = 44444

# Describe the sink

a1.sinks.k1.type = hdfs
a1.sinks.k1.hdfs.path = flume/ads/%y-%m-%d/%H
a1.sinks.k1.hdfs.fileType = DataStream

# Use a channel which buffers events in memory

a1.channels.c1.type = memory
a1.channels.c1.capacity = 10000

# Bind the source and sink to the channel

a1.sources.r1.channels = c1
a1.sinks.k1.channel = c1

flume创建文件夹flume/ads/70-01-17/02。文件夹包含文件“flumedata.timestamp”,这个时间戳有12位数字。
我的文件夹名不正确。
我能做什么?

mutmk8jj

mutmk8jj1#

我找到了。
在剖面图中,Flume应为:

a1.sinks.k1.hdfs.useLocalTimeStamp = True

相关问题