You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by zh...@apache.org on 2017/12/28 00:54:08 UTC
[04/26] hbase git commit: HBASE-19610 Fixed Checkstyle errors in
hbase-protocol and enabled Checkstyle to fail on violations
HBASE-19610 Fixed Checkstyle errors in hbase-protocol and enabled Checkstyle to fail on violations
Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/3ed68fd7
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/3ed68fd7
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/3ed68fd7
Branch: refs/heads/HBASE-19397
Commit: 3ed68fd70d7ee187553627998ee39581309296e2
Parents: 6b39062
Author: Jan Hentschel <ja...@ultratendency.com>
Authored: Sun Dec 24 13:59:27 2017 +0100
Committer: Jan Hentschel <ja...@ultratendency.com>
Committed: Wed Dec 27 17:26:54 2017 +0100
----------------------------------------------------------------------
hbase-protocol/pom.xml | 16 ++++++++++++++++
.../google/protobuf/HBaseZeroCopyByteString.java | 2 +-
.../org/apache/hadoop/hbase/util/ByteStringer.java | 8 ++++----
3 files changed, 21 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/hbase/blob/3ed68fd7/hbase-protocol/pom.xml
----------------------------------------------------------------------
diff --git a/hbase-protocol/pom.xml b/hbase-protocol/pom.xml
index d07a031..ec7f66a 100644
--- a/hbase-protocol/pom.xml
+++ b/hbase-protocol/pom.xml
@@ -112,6 +112,22 @@
</replacements>
</configuration>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-checkstyle-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>checkstyle</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>check</goal>
+ </goals>
+ <configuration>
+ <failOnViolation>true</failOnViolation>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
<pluginManagement>
<plugins>
http://git-wip-us.apache.org/repos/asf/hbase/blob/3ed68fd7/hbase-protocol/src/main/java/com/google/protobuf/HBaseZeroCopyByteString.java
----------------------------------------------------------------------
diff --git a/hbase-protocol/src/main/java/com/google/protobuf/HBaseZeroCopyByteString.java b/hbase-protocol/src/main/java/com/google/protobuf/HBaseZeroCopyByteString.java
index 9d75612..3d1953e 100644
--- a/hbase-protocol/src/main/java/com/google/protobuf/HBaseZeroCopyByteString.java
+++ b/hbase-protocol/src/main/java/com/google/protobuf/HBaseZeroCopyByteString.java
@@ -61,7 +61,7 @@ public final class HBaseZeroCopyByteString extends LiteralByteString {
/**
* Extracts the byte array from the given {@link ByteString} without copy.
* @param buf A buffer from which to extract the array. This buffer must be
- * actually an instance of a {@code LiteralByteString}.
+ * actually an instance of a {@code LiteralByteString}.
* @return byte[] representation
*/
public static byte[] zeroCopyGetBytes(final ByteString buf) {
http://git-wip-us.apache.org/repos/asf/hbase/blob/3ed68fd7/hbase-protocol/src/main/java/org/apache/hadoop/hbase/util/ByteStringer.java
----------------------------------------------------------------------
diff --git a/hbase-protocol/src/main/java/org/apache/hadoop/hbase/util/ByteStringer.java b/hbase-protocol/src/main/java/org/apache/hadoop/hbase/util/ByteStringer.java
index 65f1cc6..581741d 100644
--- a/hbase-protocol/src/main/java/org/apache/hadoop/hbase/util/ByteStringer.java
+++ b/hbase-protocol/src/main/java/org/apache/hadoop/hbase/util/ByteStringer.java
@@ -17,18 +17,18 @@
*/
package org.apache.hadoop.hbase.util;
+import com.google.protobuf.ByteString;
+import com.google.protobuf.HBaseZeroCopyByteString;
+
import org.apache.yetus.audience.InterfaceAudience;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import com.google.protobuf.ByteString;
-import com.google.protobuf.HBaseZeroCopyByteString;
-
/**
* Hack to workaround HBASE-10304 issue that keeps bubbling up when a mapreduce context.
*/
@InterfaceAudience.Private
-public class ByteStringer {
+public final class ByteStringer {
private static final Logger LOG = LoggerFactory.getLogger(ByteStringer.class);
/**