Review Board 1.7.22


FLUME-1184: TestFileChannel.testThreaded fails sometimes

Review Request #5054 - Created May 7, 2012 and submitted

Brock Noland
trunk
FLUME-1184
Reviewers
Flume
aprabhakar
flume-git
TestFileChannel.testThreaded has a race condition due to FileChannel.FileBackedTransaction not blocking. Sometimes the take threads will find no events on the queue and quit. This patch addresses this issue and additionally addresses a few issues found in the Log class:

1) We are not closing files open for gets()
2) removeOldLogs could be called after the log as been closed by the background thread (identified while fixing #1).
All unit tests pass and the unit test in question passed 1000 times in a row which it had previously failed to do.
Review request changed
Updated (Aug. 21, 2012, 3:06 p.m.)
  • changed from pending to submitted