Skip to content

Conversation

zhjwpku
Copy link
Contributor

@zhjwpku zhjwpku commented Oct 23, 2019

When we do rename operation for directory,
if the src directory or any of its descendant is snapshottable
and the dst directory or its any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

V2:
1. reduce duplicate code
2. take directory rename overwrite into consideration

Signed-off-by: Zhao Junwang zhjwpku@gmail.com

@zhjwpku
Copy link
Contributor Author

zhjwpku commented Oct 23, 2019

@manojpec, please help to review this patch :)

@jojochuang
Copy link
Contributor

@bshashikant could you help review this PR?

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 2075 Docker mode activated.
_ Prechecks _
+1 dupname 1 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
-1 test4tests 0 The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ trunk Compile Tests _
+1 mvninstall 1271 trunk passed
+1 compile 65 trunk passed
+1 checkstyle 47 trunk passed
+1 mvnsite 71 trunk passed
+1 shadedclient 957 branch has no errors when building and testing our client artifacts.
+1 javadoc 82 trunk passed
0 spotbugs 180 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 177 trunk passed
_ Patch Compile Tests _
+1 mvninstall 65 the patch passed
+1 compile 61 the patch passed
+1 javac 61 the patch passed
-0 checkstyle 42 hadoop-hdfs-project/hadoop-hdfs: The patch generated 2 new + 28 unchanged - 0 fixed = 30 total (was 28)
+1 mvnsite 66 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 886 patch has no errors when building and testing our client artifacts.
+1 javadoc 75 the patch passed
+1 findbugs 180 the patch passed
_ Other Tests _
-1 unit 6257 hadoop-hdfs in the patch failed.
+1 asflicense 35 The patch does not generate ASF License warnings.
12478
Reason Tests
Failed junit tests hadoop.hdfs.server.namenode.snapshot.TestSnapshottableDirListing
hadoop.hdfs.server.namenode.snapshot.TestRenameWithSnapshots
hadoop.hdfs.server.namenode.TestNameNodeMetadataConsistency
hadoop.hdfs.TestReconstructStripedFile
hadoop.hdfs.TestReconstructStripedFileWithRandomECPolicy
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/1/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux f5150bcc6203 4.15.0-65-generic #74-Ubuntu SMP Tue Sep 17 17:06:04 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 1d5d7d0
Default Java 1.8.0_222
checkstyle https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/1/artifact/out/diff-checkstyle-hadoop-hdfs-project_hadoop-hdfs.txt
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/1/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/1/testReport/
Max. process+thread count 2829 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/1/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

Copy link
Contributor

@dineshchitlangia dineshchitlangia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good. Requested a small change inline.

@zhjwpku
Copy link
Contributor Author

zhjwpku commented Oct 24, 2019

This patch misses considering dir to dir overwrite scenario, will modify and push later, thx.

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 2112 Docker mode activated.
_ Prechecks _
+1 dupname 0 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
-1 test4tests 0 The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ trunk Compile Tests _
+1 mvninstall 1112 trunk passed
+1 compile 66 trunk passed
+1 checkstyle 48 trunk passed
+1 mvnsite 75 trunk passed
+1 shadedclient 856 branch has no errors when building and testing our client artifacts.
+1 javadoc 85 trunk passed
0 spotbugs 168 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 165 trunk passed
_ Patch Compile Tests _
+1 mvninstall 65 the patch passed
+1 compile 62 the patch passed
+1 javac 62 the patch passed
-0 checkstyle 40 hadoop-hdfs-project/hadoop-hdfs: The patch generated 2 new + 28 unchanged - 0 fixed = 30 total (was 28)
+1 mvnsite 66 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 794 patch has no errors when building and testing our client artifacts.
+1 javadoc 77 the patch passed
+1 findbugs 168 the patch passed
_ Other Tests _
-1 unit 8200 hadoop-hdfs in the patch failed.
+1 asflicense 42 The patch does not generate ASF License warnings.
14114
Reason Tests
Failed junit tests hadoop.hdfs.server.namenode.TestRedudantBlocks
hadoop.hdfs.server.namenode.snapshot.TestSnapshottableDirListing
hadoop.hdfs.server.namenode.snapshot.TestRandomOpsWithSnapshots
hadoop.hdfs.server.namenode.TestFsck
hadoop.hdfs.server.namenode.ha.TestHAAppend
hadoop.hdfs.server.namenode.snapshot.TestRenameWithSnapshots
hadoop.hdfs.server.namenode.ha.TestPipelinesFailover
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/2/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux a017f944f4fe 4.15.0-65-generic #74-Ubuntu SMP Tue Sep 17 17:06:04 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 1d5d7d0
Default Java 1.8.0_222
checkstyle https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/2/artifact/out/diff-checkstyle-hadoop-hdfs-project_hadoop-hdfs.txt
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/2/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/2/testReport/
Max. process+thread count 3910 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/2/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 66 Docker mode activated.
_ Prechecks _
+1 dupname 1 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
-1 test4tests 0 The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ trunk Compile Tests _
+1 mvninstall 1266 trunk passed
+1 compile 64 trunk passed
+1 checkstyle 49 trunk passed
+1 mvnsite 71 trunk passed
+1 shadedclient 963 branch has no errors when building and testing our client artifacts.
+1 javadoc 79 trunk passed
0 spotbugs 179 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 176 trunk passed
_ Patch Compile Tests _
+1 mvninstall 65 the patch passed
+1 compile 61 the patch passed
+1 javac 61 the patch passed
-0 checkstyle 40 hadoop-hdfs-project/hadoop-hdfs: The patch generated 5 new + 38 unchanged - 0 fixed = 43 total (was 38)
+1 mvnsite 66 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 873 patch has no errors when building and testing our client artifacts.
+1 javadoc 78 the patch passed
+1 findbugs 180 the patch passed
_ Other Tests _
-1 unit 6313 hadoop-hdfs in the patch failed.
+1 asflicense 36 The patch does not generate ASF License warnings.
10518
Reason Tests
Failed junit tests hadoop.hdfs.server.namenode.snapshot.TestRenameWithSnapshots
hadoop.hdfs.server.namenode.snapshot.TestRandomOpsWithSnapshots
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/3/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux 9bccbd5c974f 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / ac6b6a6
Default Java 1.8.0_222
checkstyle https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/3/artifact/out/diff-checkstyle-hadoop-hdfs-project_hadoop-hdfs.txt
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/3/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/3/testReport/
Max. process+thread count 2896 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/3/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

@jojochuang
Copy link
Contributor

TestRenameWithSnapshots is unrelated, due to HDFS-14910, but please check TestRandomOpsWithSnapshots

@zhjwpku
Copy link
Contributor Author

zhjwpku commented Oct 24, 2019

@jojochuang can you pls tell me how can I run the unittest locally, I see the jenkins job runs

/usr/bin/mvn --batch-mode -Ptest-patch -Pparallel-tests -P!shelltest -Pnative -Drequire.fuse -Drequire.openssl -Drequire.snappy -Drequire.valgrind -Drequire.test.libhadoop -Pyarn-ui clean test -fae

but I couldn't run this on my centos server

@jojochuang
Copy link
Contributor

If you have editors like IntelliJ, you can run any of the tests.
In console, you can run a specific test by mvn test -Dtest= TestRandomOpsWithSnapshots.

Double check for the failed tests. Sometimes they are flaky tests and we are okay to +1 if they don't reproduce all the time.

If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

V2:
 1. reduce duplicate code
 2. take `directory rename overwrite` into consideration

V3:
 1. fix unit test fail

Signed-off-by: Zhao Junwang <zhjwpku@gmail.com>
@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 70 Docker mode activated.
_ Prechecks _
+1 dupname 0 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
-1 test4tests 0 The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ trunk Compile Tests _
+1 mvninstall 1231 trunk passed
+1 compile 64 trunk passed
+1 checkstyle 45 trunk passed
+1 mvnsite 72 trunk passed
+1 shadedclient 938 branch has no errors when building and testing our client artifacts.
+1 javadoc 80 trunk passed
0 spotbugs 175 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 173 trunk passed
_ Patch Compile Tests _
+1 mvninstall 66 the patch passed
+1 compile 60 the patch passed
+1 javac 60 the patch passed
-0 checkstyle 40 hadoop-hdfs-project/hadoop-hdfs: The patch generated 5 new + 22 unchanged - 0 fixed = 27 total (was 22)
+1 mvnsite 65 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 868 patch has no errors when building and testing our client artifacts.
+1 javadoc 77 the patch passed
+1 findbugs 182 the patch passed
_ Other Tests _
-1 unit 6185 hadoop-hdfs in the patch failed.
+1 asflicense 35 The patch does not generate ASF License warnings.
10313
Reason Tests
Failed junit tests hadoop.hdfs.TestRollingUpgrade
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/4/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux 7088665440e1 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 8625265
Default Java 1.8.0_222
checkstyle https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/4/artifact/out/diff-checkstyle-hadoop-hdfs-project_hadoop-hdfs.txt
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/4/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/4/testReport/
Max. process+thread count 2634 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/4/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

@zhjwpku
Copy link
Contributor Author

zhjwpku commented Oct 25, 2019

@jojochuang I didn't get TestRollingUpgrade failed when I run it locally. Can you pls help to check is it a flaky test? Following it error message:

[ERROR] Tests run: 13, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 141.704 s <<< FAILURE! - in org.apache.hadoop.hdfs.TestRollingUpgrade
[ERROR] testRollback(org.apache.hadoop.hdfs.TestRollingUpgrade)  Time elapsed: 84.111 s  <<< FAILURE!
java.lang.AssertionError: Test resulted in an unexpected exit
	at org.apache.hadoop.hdfs.MiniDFSCluster.shutdown(MiniDFSCluster.java:2073)
	at org.apache.hadoop.hdfs.MiniDFSCluster.shutdown(MiniDFSCluster.java:2060)
	at org.apache.hadoop.hdfs.MiniDFSCluster.shutdown(MiniDFSCluster.java:2053)
	at org.apache.hadoop.hdfs.TestRollingUpgrade.testRollback(TestRollingUpgrade.java:354)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
	at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
	at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:273)
	at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:238)
	at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
	at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:384)
	at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:345)
	at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:126)
	at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:418)

Copy link
Contributor

@jojochuang jojochuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add test please?

Signed-off-by: Zhao Junwang <zhjwpku@gmail.com>
@zhjwpku zhjwpku requested a review from jojochuang October 26, 2019 16:14
@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 75 Docker mode activated.
_ Prechecks _
+1 dupname 0 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
+1 test4tests 0 The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+1 mvninstall 1242 trunk passed
+1 compile 68 trunk passed
+1 checkstyle 48 trunk passed
+1 mvnsite 70 trunk passed
+1 shadedclient 958 branch has no errors when building and testing our client artifacts.
+1 javadoc 81 trunk passed
0 spotbugs 175 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 173 trunk passed
_ Patch Compile Tests _
+1 mvninstall 67 the patch passed
+1 compile 59 the patch passed
+1 javac 59 the patch passed
-0 checkstyle 44 hadoop-hdfs-project/hadoop-hdfs: The patch generated 11 new + 150 unchanged - 0 fixed = 161 total (was 150)
+1 mvnsite 65 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 870 patch has no errors when building and testing our client artifacts.
+1 javadoc 80 the patch passed
+1 findbugs 180 the patch passed
_ Other Tests _
-1 unit 6181 hadoop-hdfs in the patch failed.
+1 asflicense 35 The patch does not generate ASF License warnings.
10366
Reason Tests
Failed junit tests hadoop.hdfs.server.datanode.TestBlockRecovery
hadoop.hdfs.TestRollingUpgrade
hadoop.hdfs.server.namenode.ha.TestBootstrapAliasmap
hadoop.hdfs.tools.TestDFSZKFailoverController
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/5/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux dcc817ff0aa2 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 7be5508
Default Java 1.8.0_222
checkstyle https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/5/artifact/out/diff-checkstyle-hadoop-hdfs-project_hadoop-hdfs.txt
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/5/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/5/testReport/
Max. process+thread count 2525 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/5/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 1816 Docker mode activated.
_ Prechecks _
+1 dupname 1 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
+1 test4tests 0 The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+1 mvninstall 1114 trunk passed
+1 compile 66 trunk passed
+1 checkstyle 50 trunk passed
+1 mvnsite 70 trunk passed
+1 shadedclient 858 branch has no errors when building and testing our client artifacts.
+1 javadoc 84 trunk passed
0 spotbugs 168 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 165 trunk passed
_ Patch Compile Tests _
+1 mvninstall 67 the patch passed
+1 compile 59 the patch passed
+1 javac 59 the patch passed
-0 checkstyle 44 hadoop-hdfs-project/hadoop-hdfs: The patch generated 2 new + 150 unchanged - 0 fixed = 152 total (was 150)
+1 mvnsite 66 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 779 patch has no errors when building and testing our client artifacts.
+1 javadoc 81 the patch passed
+1 findbugs 168 the patch passed
_ Other Tests _
-1 unit 5212 hadoop-hdfs in the patch failed.
+1 asflicense 41 The patch does not generate ASF License warnings.
10826
Reason Tests
Failed junit tests hadoop.hdfs.TestFileChecksumCompositeCrc
hadoop.hdfs.server.namenode.snapshot.TestRenameWithSnapshots
hadoop.hdfs.TestReconstructStripedFileWithRandomECPolicy
hadoop.hdfs.TestErasureCodingPolicies
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/6/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux 65978886f369 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 7be5508
Default Java 1.8.0_222
checkstyle https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/6/artifact/out/diff-checkstyle-hadoop-hdfs-project_hadoop-hdfs.txt
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/6/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/6/testReport/
Max. process+thread count 5375 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/6/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

Signed-off-by: Zhao Junwang <zhjwpku@gmail.com>
@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
0 reexec 77 Docker mode activated.
_ Prechecks _
+1 dupname 0 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
+1 test4tests 0 The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+1 mvninstall 1080 trunk passed
+1 compile 66 trunk passed
+1 checkstyle 49 trunk passed
+1 mvnsite 74 trunk passed
+1 shadedclient 874 branch has no errors when building and testing our client artifacts.
+1 javadoc 82 trunk passed
0 spotbugs 168 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 165 trunk passed
_ Patch Compile Tests _
+1 mvninstall 65 the patch passed
+1 compile 63 the patch passed
+1 javac 63 the patch passed
+1 checkstyle 44 the patch passed
+1 mvnsite 65 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 787 patch has no errors when building and testing our client artifacts.
+1 javadoc 78 the patch passed
+1 findbugs 167 the patch passed
_ Other Tests _
+1 unit 6899 hadoop-hdfs in the patch passed.
+1 asflicense 43 The patch does not generate ASF License warnings.
10756
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/7/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux 7fd0507f8d4a 4.15.0-65-generic #74-Ubuntu SMP Tue Sep 17 17:06:04 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 7be5508
Default Java 1.8.0_222
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/7/testReport/
Max. process+thread count 3697 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/7/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

@zhjwpku
Copy link
Contributor Author

zhjwpku commented Oct 27, 2019

@jojochuang @dineshchitlangia finally hadoop-yetus report +1 overall, can you please review and merge this PR.

Copy link
Contributor

@jojochuang jojochuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the patch. I think it's almost good with a nit.
Our tests are flaky all the time so don't expect it to +1 for you. As long as the flaky tests don't reproduce consistently I am okay.

* src) which do not have snapshots yet. If this list is not empty, that
* means rename src has snapshottable descendant directories.
*/
if (snapshottableDirs != null && snapshottableDirs.size() > 0) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was concerned about the case where the source already has a snapshot.
But turns out that case is already handled before this patch with the following exception
The directory /dir1/foo cannot be deleted since /dir1/foo is snapshottable and already has snapshots at org.apache.hadoop.hdfs.server.namenode.FSDirSnapshotOp.checkSnapshot(FSDirSnapshotOp.java:297)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that's it ;)

Signed-off-by: Zhao Junwang <zhjwpku@gmail.com>
@zhjwpku zhjwpku requested a review from jojochuang October 29, 2019 00:58
Copy link
Contributor

@jojochuang jojochuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 pending Jenkins

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
0 reexec 2120 Docker mode activated.
_ Prechecks _
+1 dupname 0 No case conflicting files found.
+1 @author 0 The patch does not contain any @author tags.
+1 test4tests 0 The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+1 mvninstall 1095 trunk passed
+1 compile 67 trunk passed
+1 checkstyle 51 trunk passed
+1 mvnsite 76 trunk passed
+1 shadedclient 879 branch has no errors when building and testing our client artifacts.
+1 javadoc 82 trunk passed
0 spotbugs 167 Used deprecated FindBugs config; considering switching to SpotBugs.
+1 findbugs 165 trunk passed
_ Patch Compile Tests _
+1 mvninstall 64 the patch passed
+1 compile 56 the patch passed
+1 javac 56 the patch passed
+1 checkstyle 43 the patch passed
+1 mvnsite 65 the patch passed
+1 whitespace 0 The patch has no whitespace issues.
+1 shadedclient 778 patch has no errors when building and testing our client artifacts.
+1 javadoc 78 the patch passed
+1 findbugs 170 the patch passed
_ Other Tests _
-1 unit 6835 hadoop-hdfs in the patch failed.
+1 asflicense 42 The patch does not generate ASF License warnings.
12746
Reason Tests
Failed junit tests hadoop.hdfs.server.namenode.ha.TestFailureToReadEdits
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/8/artifact/out/Dockerfile
GITHUB PR #1670
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle
uname Linux ad28146b21b9 4.15.0-65-generic #74-Ubuntu SMP Tue Sep 17 17:06:04 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality personality/hadoop.sh
git revision trunk / 30ed24a
Default Java 1.8.0_222
unit https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/8/artifact/out/patch-unit-hadoop-hdfs-project_hadoop-hdfs.txt
Test Results https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/8/testReport/
Max. process+thread count 3866 (vs. ulimit of 5500)
modules C: hadoop-hdfs-project/hadoop-hdfs U: hadoop-hdfs-project/hadoop-hdfs
Console output https://builds.apache.org/job/hadoop-multibranch/job/PR-1670/8/console
versions git=2.7.4 maven=3.3.9 findbugs=3.1.0-RC1
Powered by Apache Yetus 0.10.0 http://yetus.apache.org

This message was automatically generated.

@bshashikant
Copy link
Contributor

The changes look good to me as well. +1

@jojochuang jojochuang merged commit de6b8b0 into apache:trunk Nov 1, 2019
@jojochuang
Copy link
Contributor

Thanks @bshashikant for review and @zhjwpku for the patch!

asfgit pushed a commit that referenced this pull request Nov 1, 2019
If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

Reviewed-by: Shashikant Banerjee <shashikant@apache.org>
(cherry picked from commit de6b8b0)
(cherry picked from commit c9fc118)
asfgit pushed a commit that referenced this pull request Nov 1, 2019
If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

Reviewed-by: Shashikant Banerjee <shashikant@apache.org>
(cherry picked from commit de6b8b0)
RogPodge pushed a commit to RogPodge/hadoop that referenced this pull request Mar 25, 2020
If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

Reviewed-by: Shashikant Banerjee <shashikant@apache.org>
bentito pushed a commit to bentito/hadoop that referenced this pull request Dec 2, 2020
If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

Reviewed-by: Shashikant Banerjee <shashikant@apache.org>
(cherry picked from commit de6b8b0)
(cherry picked from commit c9fc118)
bentito pushed a commit to bentito/hadoop that referenced this pull request Dec 3, 2020
If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

Reviewed-by: Shashikant Banerjee <shashikant@apache.org>
(cherry picked from commit de6b8b0)
(cherry picked from commit c9fc118)
jojochuang added a commit to jojochuang/hadoop that referenced this pull request May 23, 2023
If the src directory or any of its descendant is snapshottable
and the dst directory or any of its ancestors is snapshottable,
we consider this as nested snapshot, which should be denied.

Reviewed-by: Shashikant Banerjee <shashikant@apache.org>
(cherry picked from commit de6b8b0)
(cherry picked from commit c9fc118)
(cherry picked from commit cda8b2a)
Change-Id: I5f3b2ee646e5ac29836b589fa317f72f2c023a11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants