[
https://issues.apache.org/jira/browse/FLUME-3223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16630289#comment-16630289
]
ASF GitHub Bot commented on FLUME-3223:
---------------------------------------
GitHub user majorendre opened a pull request:
https://github.com/apache/flume/pull/229
FLUME-3223 Flume HDFS Sink should retry close prior release lease
This is based on @mcsanady 's original pull request #202
I have took the test changes from him but reworked the new feature
implementation since it failed some unit tests.
Previously when a close failed we immediately did a recover lease. This PR
introduces a background retry mechanism. It uses the already existing
"hdfs.closeTries" parameter. Unfortunately it has infinite retries by default,
that seems a bit too long for me.
I also did a minimal code clean up.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/majorendre/flume FLUME-3223
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/flume/pull/229.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #229
----
commit 5514f0489ae6091bec5eea814a4c8a9990eede35
Author: Endre Major <emajor@...>
Date: 2018-09-27T12:05:38Z
FLUME-3223 Flume HDFS Sink should retry close prior release lease
----
> Flume HDFS Sink should retry close prior to performing a recoverLease
> ---------------------------------------------------------------------
>
> Key: FLUME-3223
> URL: https://issues.apache.org/jira/browse/FLUME-3223
> Project: Flume
> Issue Type: Improvement
> Reporter: Miklos Csanady
> Assignee: Endre Major
> Priority: Major
>
> Flume HDFS Sink will currently only attempt to close a file once, and if that
> fails, it will move to recoverLease. This appears to be causing some issues.
> The recommendation is to modify the close behavior to retry the close a
> configurable number of times with a configurable interval in between before
> attempting the recoverLease.
> There currently exists a {{closeTries}} and {{retryInterval}} property,
> however this only retries the rename operation, not the close operation as
> seen in the documentation:
> {quote}The file may still remain open if the close call fails but the data
> will be intact and in this case, the file will be closed only after a Flume
> restart.
> {quote}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]