Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/10634 )
Change subject: IMPALA-7110. Fix errors from error-prone ...................................................................... IMPALA-7110. Fix errors from error-prone * Fixes several cases of Preconditions.checkNotNull(<bool>) which were ineffective. Instead, we should use Preconditions.checkState. * Fixed a case of synchronizing on a non-final class member, which is a bad practice. * Fixed a case of trying to stringify an array instead of using Joiner to join it to a human-readable representation. * Fixed a couple cases where the format string in String.format didn't match the number of arguments passed. * Fixed a test where PrimitiveType objects were being used to look up elements in a Map<ScalarType, String>. This would always return null, so the test was ineffective. I elected not to enable error-prone in the default maven profile since it increases compilation time noticeably. It can be enabled by running 'mvn -Perrorprone'. Even with this patch there are a bunch of warnings -- this only addresses the issues that errorprone considers "errors". Change-Id: Ie9bfadecb5b92bba4fc7921a6f87f249ed90e771 Reviewed-on: http://gerrit.cloudera.org:8080/10583 Reviewed-by: Bharath Vissapragada <[email protected]> Reviewed-by: Philip Zeyliger <[email protected]> Tested-by: Impala Public Jenkins <[email protected]> Reviewed-on: http://gerrit.cloudera.org:8080/10634 Reviewed-by: Tim Armstrong <[email protected]> --- M fe/pom.xml M fe/src/main/java/org/apache/impala/analysis/CreateUdfStmt.java M fe/src/main/java/org/apache/impala/analysis/LiteralExpr.java M fe/src/main/java/org/apache/impala/analysis/Path.java M fe/src/main/java/org/apache/impala/catalog/DiskIdMapper.java M fe/src/main/java/org/apache/impala/catalog/ScalarFunction.java M fe/src/main/java/org/apache/impala/catalog/StructType.java M fe/src/main/java/org/apache/impala/planner/HdfsScanNode.java M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java M fe/src/test/java/org/apache/impala/analysis/ParserTest.java M fe/src/test/java/org/apache/impala/hive/executor/UdfExecutorTest.java 11 files changed, 51 insertions(+), 14 deletions(-) Approvals: Tim Armstrong: Looks good to me, approved Impala Public Jenkins: Verified -- To view, visit http://gerrit.cloudera.org:8080/10634 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: 2.x Gerrit-MessageType: merged Gerrit-Change-Id: Ie9bfadecb5b92bba4fc7921a6f87f249ed90e771 Gerrit-Change-Number: 10634 Gerrit-PatchSet: 2 Gerrit-Owner: Tim Armstrong <[email protected]> Gerrit-Reviewer: Bharath Vissapragada <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Philip Zeyliger <[email protected]> Gerrit-Reviewer: Tim Armstrong <[email protected]>
