HADOOP-17315. Use shaded guava in ClientCache.java (#2398)

Added checkstyle rules to warn guava imports
This commit is contained in:
Akira Ajisaka 2020-10-20 23:25:24 +09:00 committed by GitHub
parent 30f06e0c74
commit 7b4359657f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 4 deletions

View File

@ -121,9 +121,7 @@
<!-- See http://checkstyle.sf.net/config_import.html -->
<module name="IllegalImport">
<property name="regexp" value="true"/>
<property name="illegalPkgs" value="^sun\.[^.]+"/>
<property name="illegalClasses"
value="^com\.google\.common\.base\.(Optional|Function|Predicate|Supplier), ^com\.google\.common\.collect\.(ImmutableListMultimap)"/>
<property name="illegalPkgs" value="^sun\.[^.]+, ^com\.google\.common\.[^.]+"/>
</module>
<module name="RedundantImport"/>
<module name="UnusedImports"/>

View File

@ -29,7 +29,7 @@
import org.apache.hadoop.io.ObjectWritable;
import org.apache.hadoop.io.Writable;
import com.google.common.annotations.VisibleForTesting;
import org.apache.hadoop.thirdparty.com.google.common.annotations.VisibleForTesting;
/* Cache a client using its socket factory as the hash key */
@InterfaceAudience.LimitedPrivate({"HDFS", "MapReduce"})