You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by GitBox <gi...@apache.org> on 2021/01/08 10:09:26 UTC

[GitHub] [hbase] Apache9 commented on a change in pull request #2854: HBASE-25333 Add maven enforcer rule to ban VisibleForTesting imports

Apache9 commented on a change in pull request #2854:
URL: https://github.com/apache/hbase/pull/2854#discussion_r553854209



##########
File path: pom.xml
##########
@@ -1341,6 +1341,14 @@
                     <bannedImport>org.glassfish.jersey.**</bannedImport>
                   </bannedImports>
                 </restrictImports>
+                <restrictImports implementation="de.skuzzle.enforcer.restrictimports.rule.RestrictImports">
+                  <includeTestCode>true</includeTestCode>
+                  <commentLineBufferSize>512</commentLineBufferSize>
+                  <reason>Use RestrictedApi annotation in error prone instead</reason>

Review comment:
       I do not think this is the case. Even in IA.Public classes, not all the IA.Private annotations are for testing, and here we are telling a more general rule, not only for IA.Public classes. Saying that use IA.Private instead of VisibleForTesting will make developers confusing.
   Let me see if I could make things more clear.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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