You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2013/04/10 18:42:29 UTC
svn commit: r1466556 [41/41] - in /hbase/trunk: ./
hbase-client/src/main/java/org/apache/hadoop/hbase/
hbase-client/src/main/java/org/apache/hadoop/hbase/protobuf/
hbase-protocol/src/main/java/org/apache/hadoop/hbase/protobuf/generated/
hbase-protocol/...
Modified: hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/ipc/protobuf/generated/TestRpcServiceProtos.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/ipc/protobuf/generated/TestRpcServiceProtos.java?rev=1466556&r1=1466555&r2=1466556&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/ipc/protobuf/generated/TestRpcServiceProtos.java (original)
+++ hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/ipc/protobuf/generated/TestRpcServiceProtos.java Wed Apr 10 16:42:28 2013
@@ -8,28 +8,45 @@ public final class TestRpcServiceProtos
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
}
+ /**
+ * Protobuf service {@code TestProtobufRpcProto}
+ *
+ * <pre>
+ **
+ * A protobuf service for use in tests
+ * </pre>
+ */
public static abstract class TestProtobufRpcProto
implements com.google.protobuf.Service {
protected TestProtobufRpcProto() {}
-
+
public interface Interface {
+ /**
+ * <code>rpc ping(.EmptyRequestProto) returns (.EmptyResponseProto);</code>
+ */
public abstract void ping(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request,
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto> done);
-
+
+ /**
+ * <code>rpc echo(.EchoRequestProto) returns (.EchoResponseProto);</code>
+ */
public abstract void echo(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoRequestProto request,
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto> done);
-
+
+ /**
+ * <code>rpc error(.EmptyRequestProto) returns (.EmptyResponseProto);</code>
+ */
public abstract void error(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request,
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto> done);
-
+
}
-
+
public static com.google.protobuf.Service newReflectiveService(
final Interface impl) {
return new TestProtobufRpcProto() {
@@ -40,7 +57,7 @@ public final class TestRpcServiceProtos
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto> done) {
impl.ping(controller, request, done);
}
-
+
@java.lang.Override
public void echo(
com.google.protobuf.RpcController controller,
@@ -48,7 +65,7 @@ public final class TestRpcServiceProtos
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto> done) {
impl.echo(controller, request, done);
}
-
+
@java.lang.Override
public void error(
com.google.protobuf.RpcController controller,
@@ -56,10 +73,10 @@ public final class TestRpcServiceProtos
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto> done) {
impl.error(controller, request, done);
}
-
+
};
}
-
+
public static com.google.protobuf.BlockingService
newReflectiveBlockingService(final BlockingInterface impl) {
return new com.google.protobuf.BlockingService() {
@@ -67,7 +84,7 @@ public final class TestRpcServiceProtos
getDescriptorForType() {
return getDescriptor();
}
-
+
public final com.google.protobuf.Message callBlockingMethod(
com.google.protobuf.Descriptors.MethodDescriptor method,
com.google.protobuf.RpcController controller,
@@ -89,7 +106,7 @@ public final class TestRpcServiceProtos
throw new java.lang.AssertionError("Can't get here.");
}
}
-
+
public final com.google.protobuf.Message
getRequestPrototype(
com.google.protobuf.Descriptors.MethodDescriptor method) {
@@ -109,7 +126,7 @@ public final class TestRpcServiceProtos
throw new java.lang.AssertionError("Can't get here.");
}
}
-
+
public final com.google.protobuf.Message
getResponsePrototype(
com.google.protobuf.Descriptors.MethodDescriptor method) {
@@ -129,25 +146,34 @@ public final class TestRpcServiceProtos
throw new java.lang.AssertionError("Can't get here.");
}
}
-
+
};
}
-
+
+ /**
+ * <code>rpc ping(.EmptyRequestProto) returns (.EmptyResponseProto);</code>
+ */
public abstract void ping(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request,
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto> done);
-
+
+ /**
+ * <code>rpc echo(.EchoRequestProto) returns (.EchoResponseProto);</code>
+ */
public abstract void echo(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoRequestProto request,
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto> done);
-
+
+ /**
+ * <code>rpc error(.EmptyRequestProto) returns (.EmptyResponseProto);</code>
+ */
public abstract void error(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request,
com.google.protobuf.RpcCallback<org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto> done);
-
+
public static final
com.google.protobuf.Descriptors.ServiceDescriptor
getDescriptor() {
@@ -157,7 +183,7 @@ public final class TestRpcServiceProtos
getDescriptorForType() {
return getDescriptor();
}
-
+
public final void callMethod(
com.google.protobuf.Descriptors.MethodDescriptor method,
com.google.protobuf.RpcController controller,
@@ -189,7 +215,7 @@ public final class TestRpcServiceProtos
throw new java.lang.AssertionError("Can't get here.");
}
}
-
+
public final com.google.protobuf.Message
getRequestPrototype(
com.google.protobuf.Descriptors.MethodDescriptor method) {
@@ -209,7 +235,7 @@ public final class TestRpcServiceProtos
throw new java.lang.AssertionError("Can't get here.");
}
}
-
+
public final com.google.protobuf.Message
getResponsePrototype(
com.google.protobuf.Descriptors.MethodDescriptor method) {
@@ -229,23 +255,23 @@ public final class TestRpcServiceProtos
throw new java.lang.AssertionError("Can't get here.");
}
}
-
+
public static Stub newStub(
com.google.protobuf.RpcChannel channel) {
return new Stub(channel);
}
-
+
public static final class Stub extends org.apache.hadoop.hbase.ipc.protobuf.generated.TestRpcServiceProtos.TestProtobufRpcProto implements Interface {
private Stub(com.google.protobuf.RpcChannel channel) {
this.channel = channel;
}
-
+
private final com.google.protobuf.RpcChannel channel;
-
+
public com.google.protobuf.RpcChannel getChannel() {
return channel;
}
-
+
public void ping(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request,
@@ -260,7 +286,7 @@ public final class TestRpcServiceProtos
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto.class,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto.getDefaultInstance()));
}
-
+
public void echo(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoRequestProto request,
@@ -275,7 +301,7 @@ public final class TestRpcServiceProtos
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto.class,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto.getDefaultInstance()));
}
-
+
public void error(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request,
@@ -291,36 +317,36 @@ public final class TestRpcServiceProtos
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto.getDefaultInstance()));
}
}
-
+
public static BlockingInterface newBlockingStub(
com.google.protobuf.BlockingRpcChannel channel) {
return new BlockingStub(channel);
}
-
+
public interface BlockingInterface {
public org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto ping(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request)
throws com.google.protobuf.ServiceException;
-
+
public org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto echo(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoRequestProto request)
throws com.google.protobuf.ServiceException;
-
+
public org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto error(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request)
throws com.google.protobuf.ServiceException;
}
-
+
private static final class BlockingStub implements BlockingInterface {
private BlockingStub(com.google.protobuf.BlockingRpcChannel channel) {
this.channel = channel;
}
-
+
private final com.google.protobuf.BlockingRpcChannel channel;
-
+
public org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto ping(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request)
@@ -331,8 +357,8 @@ public final class TestRpcServiceProtos
request,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto.getDefaultInstance());
}
-
-
+
+
public org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto echo(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoRequestProto request)
@@ -343,8 +369,8 @@ public final class TestRpcServiceProtos
request,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EchoResponseProto.getDefaultInstance());
}
-
-
+
+
public org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto error(
com.google.protobuf.RpcController controller,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyRequestProto request)
@@ -355,11 +381,13 @@ public final class TestRpcServiceProtos
request,
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.EmptyResponseProto.getDefaultInstance());
}
-
+
}
+
+ // @@protoc_insertion_point(class_scope:TestProtobufRpcProto)
}
-
-
+
+
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
@@ -391,6 +419,6 @@ public final class TestRpcServiceProtos
org.apache.hadoop.hbase.ipc.protobuf.generated.TestProtos.getDescriptor(),
}, assigner);
}
-
+
// @@protoc_insertion_point(outer_class_scope)
}
Added: hbase/trunk/hbase-server/src/test/protobuf/README.txt
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/test/protobuf/README.txt?rev=1466556&view=auto
==============================================================================
--- hbase/trunk/hbase-server/src/test/protobuf/README.txt (added)
+++ hbase/trunk/hbase-server/src/test/protobuf/README.txt Wed Apr 10 16:42:28 2013
@@ -0,0 +1,27 @@
+These are the protobuf definition files used by tests. The produced java
+classes are generated into src/test/java/org/apache/hadoop/hbase/protobuf/generated
+and then checked in. The reasoning is that they change infrequently.
+
+To regnerate the classes after making definition file changes, ensure first that
+the protobuf protoc tool is in your $PATH (You may need to download it and build
+it first; its part of the protobuf package obtainable from here:
+http://code.google.com/p/protobuf/downloads/list). Then run the following (You
+should be able to just copy and paste the below into a terminal and hit return
+-- the protoc compiler runs fast):
+
+ UNIX_PROTO_DIR=src/test/protobuf
+ JAVA_DIR=src/test/java/
+ mkdir -p $JAVA_DIR 2> /dev/null
+ if which cygpath 2> /dev/null; then
+ PROTO_DIR=`cygpath --windows $UNIX_PROTO_DIR`
+ JAVA_DIR=`cygpath --windows $JAVA_DIR`
+ else
+ PROTO_DIR=$UNIX_PROTO_DIR
+ fi
+ for PROTO_FILE in $UNIX_PROTO_DIR/*.proto
+ do
+ protoc -I$PROTO_DIR --java_out=$JAVA_DIR $PROTO_FILE
+ done
+
+After you've done the above, check it in and then check it in (or post a patch
+on a JIRA with your definition file changes and the generated files).
Modified: hbase/trunk/pom.xml
URL: http://svn.apache.org/viewvc/hbase/trunk/pom.xml?rev=1466556&r1=1466555&r2=1466556&view=diff
==============================================================================
--- hbase/trunk/pom.xml (original)
+++ hbase/trunk/pom.xml Wed Apr 10 16:42:28 2013
@@ -891,7 +891,7 @@
<slf4j.version>1.4.3</slf4j.version>
<log4j.version>1.2.17</log4j.version>
<mockito-all.version>1.9.0</mockito-all.version>
- <protobuf.version>2.4.1</protobuf.version>
+ <protobuf.version>2.5.0</protobuf.version>
<stax-api.version>1.0.1</stax-api.version>
<thrift.version>0.9.0</thrift.version>
<zookeeper.version>3.4.5</zookeeper.version>