Adds --dry-run option to Merge#6437
Conversation
Adds the --dry-run option to both the Shell's MergeCommand and the Merge utility code. Fixes an issue where MergeExceptions were being wrapped needlessly. Adds Mock tests for MergeCommand. Adds MergeIT tests. Adds explicit failure message for attempting to merge the accumulo.root table instead of just silently doing nothing.
| long newGoalSize = tableConfig.getAsBytes(Property.TABLE_SPLIT_THRESHOLD); | ||
| message("Invalid goal size: " + opts.goalSize + " Using the " | ||
| + Property.TABLE_SPLIT_THRESHOLD.getKey() + " value of : " + newGoalSize); | ||
| opts.goalSize = newGoalSize; |
There was a problem hiding this comment.
This gives more information for the current behavior and doesn't change the current behavior. However, I keep thinking that a goal size of 0 is entirely valid, and makes much more sense than a goal size of 1 when trying to merge away consecutive empty tablets.
Having a goal size of zero auto-magically readjust to the tablet split threshold seems nonsensical to me when an empty size is valid.
I'm glad that this message was added, but I think it might be nice to change the behavior so that you don't have to do -s 1 to get an effective goal size of 0.
There was a problem hiding this comment.
A behavior change could be done later, 4.0 rather than change 2.1
There was a problem hiding this comment.
Yes I agree that a size of 0 should be a valid value, but I thought that would be a large behavior change in a patch release.
There was a problem hiding this comment.
2.1 could support a behavior change by adding a new MergeTablets command in the shell.
The old MergeCommand behavior is preserved but we can support a new command with different behavior.
Fixes imports for EasyMock and changes description message
Adds the --dry-run option to both the Shell's MergeCommand and the Merge utility code.
Fixes an issue where MergeExceptions were being wrapped needlessly.
Adds Mock tests for MergeCommand.
Adds MergeIT tests.
Adds explicit failure message for attempting to merge the accumulo.root table instead of just silently doing nothing.
Adds explicit message if the goalSize is invalid.
closes #6414