kudu-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ale...@apache.org
Subject kudu git commit: [java] fixed checkstyle warnings
Date Tue, 13 Jun 2017 19:06:13 GMT
Repository: kudu
Updated Branches:
  refs/heads/master 50c7d3249 -> e68a7953a


[java] fixed checkstyle warnings

This patch does not contain any functional changes.

Change-Id: If8160a5c274704b71067ba988f73dde6443bfe03
Reviewed-on: http://gerrit.cloudera.org:8080/7147
Tested-by: Alexey Serbin <aserbin@cloudera.com>
Reviewed-by: Todd Lipcon <todd@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/e68a7953
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/e68a7953
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/e68a7953

Branch: refs/heads/master
Commit: e68a7953a7710155342dcdd03d59c7e1833fbc13
Parents: 50c7d32
Author: Alexey Serbin <aserbin@cloudera.com>
Authored: Sat Jun 10 10:34:34 2017 -0700
Committer: Alexey Serbin <aserbin@cloudera.com>
Committed: Tue Jun 13 18:56:56 2017 +0000

----------------------------------------------------------------------
 .../tools/IntegrationTestBigLinkedList.java      | 19 +++++++++++++++++--
 .../kudu/client/AbstractKuduScannerBuilder.java  |  2 +-
 .../org/apache/kudu/client/AsyncKuduScanner.java |  3 ++-
 .../java/org/apache/kudu/client/KuduScanner.java |  1 +
 .../java/org/apache/kudu/client/PartialRow.java  | 18 +++++++++---------
 .../apache/kudu/client/TableLocationsCache.java  |  4 +++-
 .../kudu/mapreduce/KuduTableMapReduceUtil.java   |  3 +--
 7 files changed, 34 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-client-tools/src/main/java/org/apache/kudu/mapreduce/tools/IntegrationTestBigLinkedList.java
----------------------------------------------------------------------
diff --git a/java/kudu-client-tools/src/main/java/org/apache/kudu/mapreduce/tools/IntegrationTestBigLinkedList.java
b/java/kudu-client-tools/src/main/java/org/apache/kudu/mapreduce/tools/IntegrationTestBigLinkedList.java
index beddb71..b16a2d1 100644
--- a/java/kudu-client-tools/src/main/java/org/apache/kudu/mapreduce/tools/IntegrationTestBigLinkedList.java
+++ b/java/kudu-client-tools/src/main/java/org/apache/kudu/mapreduce/tools/IntegrationTestBigLinkedList.java
@@ -15,6 +15,23 @@
 
 package org.apache.kudu.mapreduce.tools;
 
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_CLIENT;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_KEY_ONE;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_KEY_TWO;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_PREV_ONE;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_PREV_TWO;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_ROW_ID;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.COLUMN_UPDATE_COUNT;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.Counts;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.DEFAULT_HEADS_TABLE_NAME;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.DEFAULT_TABLE_NAME;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.HEADS_TABLE_NAME_KEY;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.TABLE_NAME_KEY;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.Xoroshiro128PlusRandom;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.getCreateTableOptions;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.getHeadsTableSchema;
+import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.getTableSchema;
+
 import java.io.DataInput;
 import java.io.DataOutput;
 import java.io.IOException;
@@ -82,8 +99,6 @@ import org.apache.kudu.mapreduce.CommandLineParser;
 import org.apache.kudu.mapreduce.KuduTableMapReduceUtil;
 import org.apache.kudu.util.Pair;
 
-import static org.apache.kudu.mapreduce.tools.BigLinkedListCommon.*;
-
 /**
  * <p>
  * This is an integration test borrowed from goraci, written by Keith Turner,

http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-client/src/main/java/org/apache/kudu/client/AbstractKuduScannerBuilder.java
----------------------------------------------------------------------
diff --git a/java/kudu-client/src/main/java/org/apache/kudu/client/AbstractKuduScannerBuilder.java
b/java/kudu-client/src/main/java/org/apache/kudu/client/AbstractKuduScannerBuilder.java
index 12f4971..f364565 100644
--- a/java/kudu-client/src/main/java/org/apache/kudu/client/AbstractKuduScannerBuilder.java
+++ b/java/kudu-client/src/main/java/org/apache/kudu/client/AbstractKuduScannerBuilder.java
@@ -74,7 +74,7 @@ public abstract class AbstractKuduScannerBuilder
     return (S) this;
   }
 
- /**
+  /**
    * Make scans resumable at another tablet server if current server fails if
    * isFaultTolerant is true.
    * <p>

http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-client/src/main/java/org/apache/kudu/client/AsyncKuduScanner.java
----------------------------------------------------------------------
diff --git a/java/kudu-client/src/main/java/org/apache/kudu/client/AsyncKuduScanner.java b/java/kudu-client/src/main/java/org/apache/kudu/client/AsyncKuduScanner.java
index f2e9f0a..0e7fb7a 100644
--- a/java/kudu-client/src/main/java/org/apache/kudu/client/AsyncKuduScanner.java
+++ b/java/kudu-client/src/main/java/org/apache/kudu/client/AsyncKuduScanner.java
@@ -862,9 +862,10 @@ public final class AsyncKuduScanner {
               Status status = Status.fromTabletServerErrorPB(error);
               throw new ScannerExpiredException(status);
             }
+            // fall through
           default:
             break;
-          }
+        }
       }
       RowResultIterator iterator = RowResultIterator.makeRowResultIterator(
           deadlineTracker.getElapsedMillis(), tsUUID, schema, resp.getData(),

http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-client/src/main/java/org/apache/kudu/client/KuduScanner.java
----------------------------------------------------------------------
diff --git a/java/kudu-client/src/main/java/org/apache/kudu/client/KuduScanner.java b/java/kudu-client/src/main/java/org/apache/kudu/client/KuduScanner.java
index 85fe3b3..5108b94 100644
--- a/java/kudu-client/src/main/java/org/apache/kudu/client/KuduScanner.java
+++ b/java/kudu-client/src/main/java/org/apache/kudu/client/KuduScanner.java
@@ -18,6 +18,7 @@
 package org.apache.kudu.client;
 
 import com.google.common.annotations.VisibleForTesting;
+
 import org.apache.kudu.Schema;
 import org.apache.kudu.annotations.InterfaceAudience;
 import org.apache.kudu.annotations.InterfaceStability;

http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-client/src/main/java/org/apache/kudu/client/PartialRow.java
----------------------------------------------------------------------
diff --git a/java/kudu-client/src/main/java/org/apache/kudu/client/PartialRow.java b/java/kudu-client/src/main/java/org/apache/kudu/client/PartialRow.java
index f31d71a..9a89442 100644
--- a/java/kudu-client/src/main/java/org/apache/kudu/client/PartialRow.java
+++ b/java/kudu-client/src/main/java/org/apache/kudu/client/PartialRow.java
@@ -26,6 +26,7 @@ import java.util.ListIterator;
 
 import com.google.common.base.Preconditions;
 import com.google.common.collect.Lists;
+import org.jboss.netty.util.CharsetUtil;
 
 import org.apache.kudu.ColumnSchema;
 import org.apache.kudu.Schema;
@@ -33,7 +34,6 @@ import org.apache.kudu.Type;
 import org.apache.kudu.annotations.InterfaceAudience;
 import org.apache.kudu.annotations.InterfaceStability;
 import org.apache.kudu.util.StringUtil;
-import org.jboss.netty.util.CharsetUtil;
 
 /**
  * Class used to represent parts of a row along with its schema.<p>
@@ -691,6 +691,14 @@ public class PartialRow {
     // We don't set anything in row alloc, it will be managed at encoding time.
   }
 
+  /**
+   * Get the list variable length data cells that were added to this row.
+   * @return a list of binary data, may be empty
+   */
+  List<ByteBuffer> getVarLengthData() {
+    return varLengthData;
+  }
+
   private ByteBuffer getVarLengthData(int columnIndex) {
     return varLengthData.get(columnIndex).duplicate();
   }
@@ -1335,14 +1343,6 @@ public class PartialRow {
   }
 
   /**
-   * Get the list variable length data cells that were added to this row.
-   * @return a list of binary data, may be empty
-   */
-  List<ByteBuffer> getVarLengthData() {
-    return varLengthData;
-  }
-
-  /**
    * Get the byte array that contains all the data added to this partial row. Variable length
data
    * is contained separately, see {@link #getVarLengthData()}. In their place you'll find
their
    * index in that list and their size.

http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-client/src/main/java/org/apache/kudu/client/TableLocationsCache.java
----------------------------------------------------------------------
diff --git a/java/kudu-client/src/main/java/org/apache/kudu/client/TableLocationsCache.java
b/java/kudu-client/src/main/java/org/apache/kudu/client/TableLocationsCache.java
index 7b60579..b51480a 100644
--- a/java/kudu-client/src/main/java/org/apache/kudu/client/TableLocationsCache.java
+++ b/java/kudu-client/src/main/java/org/apache/kudu/client/TableLocationsCache.java
@@ -220,7 +220,9 @@ class TableLocationsCache {
     try {
       Iterator<Map.Entry<byte[], Entry>> it = entries.entrySet().iterator();
       while (it.hasNext()) {
-        if (it.next().getValue().isNonCoveredRange()) it.remove();
+        if (it.next().getValue().isNonCoveredRange()) {
+          it.remove();
+        }
       }
     } finally {
       rwl.writeLock().unlock();

http://git-wip-us.apache.org/repos/asf/kudu/blob/e68a7953/java/kudu-mapreduce/src/main/java/org/apache/kudu/mapreduce/KuduTableMapReduceUtil.java
----------------------------------------------------------------------
diff --git a/java/kudu-mapreduce/src/main/java/org/apache/kudu/mapreduce/KuduTableMapReduceUtil.java
b/java/kudu-mapreduce/src/main/java/org/apache/kudu/mapreduce/KuduTableMapReduceUtil.java
index cb6bc8d..74a5849 100644
--- a/java/kudu-mapreduce/src/main/java/org/apache/kudu/mapreduce/KuduTableMapReduceUtil.java
+++ b/java/kudu-mapreduce/src/main/java/org/apache/kudu/mapreduce/KuduTableMapReduceUtil.java
@@ -29,10 +29,9 @@ import java.util.Map;
 import java.util.Set;
 import java.util.zip.ZipEntry;
 import java.util.zip.ZipFile;
-
-import com.google.common.base.Preconditions;
 import javax.security.auth.Subject;
 
+import com.google.common.base.Preconditions;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.commons.net.util.Base64;


Mime
View raw message