FLUME-1763: FileChannel Checkpoints should not be done without free space
Review Request #8379 - Created Dec. 6, 2012 and submitted
Adds a parameter which can be configured by defaults to 500MB. We will refuse to checkpoint or perform log writes in this case.
Two unit tests added.
|Needs to go before the log acquire or in the try block||Brock Noland||Dec. 6, 2012, 10:02 p.m.||Open|
Posted (Dec. 10, 2012, 9:54 p.m.)
Generally looks good, but I am confused about the configuration code.
Why do this when you are taking the max of this value and FileChannelConfiguration.FLOOR_MINIMUM_REQUIRED_SPACE later? Did you want to do a Math.max here?
Looks like you are checking for min of the configured value and FileChannelConfiguration.FLOOR_MINIMUM_REQUIRED_SPACE in FileChannel.java and you are checking the max of that value and FileChannelConfiguration.FLOOR_MINIMUM_REQUIRED_SPACE. Doing both these together means that minimumRequiredSpace is always equal to FileChannelConfiguration.FLOOR_MINIMUM_REQUIRED_SPACE. Am I missing something here?
Posted (Dec. 10, 2012, 11:36 p.m.)
Review request changed
Updated (Dec. 11, 2012, 4:30 p.m.)
- changed from pending to submitted