Updated Branches: refs/heads/trunk 6a188276d -> 93c598fe9
FLUME-1531. Flume User Guide should provide more details on configuring the timestamp interceptor. (Kathleen Ting via Hari Shreedharan) Project: http://git-wip-us.apache.org/repos/asf/flume/repo Commit: http://git-wip-us.apache.org/repos/asf/flume/commit/93c598fe Tree: http://git-wip-us.apache.org/repos/asf/flume/tree/93c598fe Diff: http://git-wip-us.apache.org/repos/asf/flume/diff/93c598fe Branch: refs/heads/trunk Commit: 93c598fe9cc83338bbd36896aa54d2dca603af2d Parents: 6a18827 Author: Hari Shreedharan <[email protected]> Authored: Fri Aug 31 12:50:04 2012 -0700 Committer: Hari Shreedharan <[email protected]> Committed: Fri Aug 31 12:50:04 2012 -0700 ---------------------------------------------------------------------- flume-ng-doc/sphinx/FlumeUserGuide.rst | 9 +++++++-- 1 files changed, 7 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flume/blob/93c598fe/flume-ng-doc/sphinx/FlumeUserGuide.rst ---------------------------------------------------------------------- diff --git a/flume-ng-doc/sphinx/FlumeUserGuide.rst b/flume-ng-doc/sphinx/FlumeUserGuide.rst index be6d597..2d64249 100644 --- a/flume-ng-doc/sphinx/FlumeUserGuide.rst +++ b/flume-ng-doc/sphinx/FlumeUserGuide.rst @@ -1656,17 +1656,22 @@ are named components, here is an example of how they are created through configu .. code-block:: properties agent_foo.sources = source_foo + agent_foo.sinks = hdfs agent_foo.channels = channel-1 agent_foo.sources.source_foo.interceptors = a b agent_foo.sources.source_foo.interceptors.a.type = org.apache.flume.interceptor.HostInterceptor$Builder agent_foo.sources.source_foo.interceptors.a.preserveExisting = false agent_foo.sources.source_foo.interceptors.a.hostHeader = hostname agent_foo.sources.source_foo.interceptors.b.type = org.apache.flume.interceptor.TimestampInterceptor$Builder + agent_foo.sinks.hdfs.filePrefix = FlumeData.%{CollectorHost}.%Y-%m-%d + agent_foo.sinks.hdfs.channel = channel-1 Note that the interceptor builders are passed to the type config parameter. The interceptors are themselves configurable and can be passed configuration values just like they are passed to any other configurable component. In the above example, events are passed to the HostInterceptor first and the events returned by the HostInterceptor -are then passed along to the TimestampInterceptor. +are then passed along to the TimestampInterceptor. You can specify either the fully qualified class name (FQCN) +or the alias ``TIMESTAMP``. If you have multiple collectors writing to the same HDFS path then you could also use +the HostInterceptor. Timestamp Interceptor ~~~~~~~~~~~~~~~~~~~~~ @@ -1678,7 +1683,7 @@ can preserve an existing timestamp if it is already present in the configuration ================ ======= ======================================================================== Property Name Default Description ================ ======= ======================================================================== -**type** -- The component type name, has to be ``TIMESTAMP`` +**type** -- The component type name, has to be ``TIMESTAMP`` or the FQCN preserveExisting false If the timestamp already exists, should it be preserved - true or false ================ ======= ========================================================================
