-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HBASE-26718 HFileArchiver can remove referenced StoreFiles from the archive #4274
Conversation
@@ -185,11 +215,30 @@ private void testArchiveStoreFilesDifferentFileSystems(String walDir, String exp | |||
when(mockedFile.getPath()).thenReturn(filePath); | |||
when(mockedFileSystem.rename(any(),any())).thenReturn(true); | |||
archivingFunction.apply(conf, mockedFileSystem, mockedRegion, tableDir, family, list); | |||
ArgumentCaptor<Path> pathCaptor = ArgumentCaptor.forClass(Path.class); | |||
verify(mockedFileSystem, times(2)).rename(pathCaptor.capture(), any()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note that we used to validate that:
- we had two rename calls (one to sideline the timestamped backup, and one to actually do the archive)
- we only validated the first call - that the source file was in the archive folder... which is not the important part we want to validate here.
Now we do some improved validations depending on the scenario.
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
hbase-server/src/main/java/org/apache/hadoop/hbase/backup/HFileArchiver.java
Show resolved
Hide resolved
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
…rchive (#4274) Signed-off-by: Andrew Purtell <apurtell@apache.org>
…rchive (#4274) Signed-off-by: Andrew Purtell <apurtell@apache.org>
…rchive (#4274) Signed-off-by: Andrew Purtell <apurtell@apache.org>
…rchive (apache#4274) Signed-off-by: Andrew Purtell <apurtell@apache.org> (cherry picked from commit da2c32c) Change-Id: I1c16751230e9472f61fc0583ee3c447f29896e2d
HBASE-26718
Of particular note:
debug
toerror
as this does not seem like any condition we want to rely on.