You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@drill.apache.org by GitBox <gi...@apache.org> on 2018/08/22 20:56:42 UTC

[GitHub] jinfengni commented on a change in pull request #1397: DRILL-6633: Replace usage of Guava classes by JDK ones

jinfengni commented on a change in pull request #1397: DRILL-6633: Replace usage of Guava classes by JDK ones
URL: https://github.com/apache/drill/pull/1397#discussion_r212105336
 
 

 ##########
 File path: common/src/test/java/org/apache/drill/test/SubDirTestWatcher.java
 ##########
 @@ -83,10 +84,10 @@
   private List<Path> subDirs;
 
   protected SubDirTestWatcher(File baseDir, boolean createAtBeginning, boolean deleteAtEnd, List<Path> subDirs) {
-    this.baseDir = Preconditions.checkNotNull(baseDir);
+    this.baseDir = Objects.requireNonNull(baseDir);
     this.createAtBeginning = createAtBeginning;
     this.deleteAtEnd = deleteAtEnd;
-    this.subDirs = Preconditions.checkNotNull(subDirs);
+    this.subDirs = Objects.requireNonNull(subDirs);
 
     Preconditions.checkArgument(!subDirs.isEmpty(), "The list of subDirs is empty.");
 
 Review comment:
   I agree with what @vrozov said; technically, there seems to be no clear benefit of replacing existing `Preconditions`.   Personal preference should only apply to new contributions , not to old contributions (since the original contributor(s) could also have her/his preference). 
     

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services