Skip to content

Commit

Permalink
HBASE-20478 move hbaseanti import checks to checkstyle
Browse files Browse the repository at this point in the history
Signed-off-by: Sean Busbey <busbey@apache.org>
  • Loading branch information
madrob authored and busbey committed Apr 26, 2018
1 parent d476811 commit 90d103d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 19 deletions.
18 changes: 0 additions & 18 deletions dev-support/hbase-personality.sh
Original file line number Diff line number Diff line change
Expand Up @@ -631,24 +631,6 @@ function hbaseanti_patchfile
((result=result+1))
fi

warnings=$(${GREP} -c 'import org.apache.hadoop.classification' "${patchfile}")
if [[ ${warnings} -gt 0 ]]; then
add_vote_table -1 hbaseanti "" "The patch appears use Hadoop classification instead of HBase."
((result=result+1))
fi

warnings=$(${GREP} -c 'import org.codehaus.jackson' "${patchfile}")
if [[ ${warnings} -gt 0 ]]; then
add_vote_table -1 hbaseanti "" "The patch appears use Jackson 1 classes/annotations."
((result=result+1))
fi

warnings=$(${GREP} -cE 'org.apache.commons.logging.Log(Factory|;)' "${patchfile}")
if [[ ${warnings} -gt 0 ]]; then
add_vote_table -1 hbaseanti "" "The patch appears to use commons-logging instead of slf4j."
((result=result+1))
fi

if [[ ${result} -gt 0 ]]; then
return 1
fi
Expand Down
7 changes: 6 additions & 1 deletion hbase-checkstyle/src/main/resources/hbase/checkstyle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,12 @@
org.apache.commons.collections4,
org.apache.commons.lang,
org.apache.curator.shaded,
org.apache.htrace.shaded"/>
org.apache.hadoop.classification,
org.apache.htrace.shaded,
org.codehaus.jackson"/>
<property name="illegalClasses" value="
org.apache.commons.logging.Log,
org.apache.commons.logging.LogFactory"/>
</module>
<!-- Javadoc Checks
http://checkstyle.sourceforge.net/config_javadoc.html -->
Expand Down

0 comments on commit 90d103d

Please sign in to comment.