You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2021/08/31 21:19:45 UTC

[GitHub] [ozone] neils-dev opened a new pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

neils-dev opened a new pull request #2601:
URL: https://github.com/apache/ozone/pull/2601


   ## What changes were proposed in this pull request?
   This PR includes the Grpc server service servicing `OzoneManagerProtocol` requests over gRPC invoked by the OM.  The server consists of `GrpcOzoneManagerServer` that is started by the OM and establishes the persistent connection between the om and the s3 gateway (current port 8981 and configurable by java configuration class).  The server creates the connection with the `OzoneManagerServiceGrpc` that services `OMRequests` through the  `OzoneManagerProtocolServerSideTranslatorPB`.
   
   The `OzoneManagerServiceGrpc` requires creating a thread context '`Server.Call`' for every ratis transaction request processed through the `OzoneManagerProtocolServerSideTranslatorPB`.
   
   
   The Grpc server service is enabled / disabled through the boolean configuration key : `OZONE_OM_S3_GPRC_SERVER_ENABLED` and corresponding property `ozone.om.s3.grpc.server_enabled`.  
   
   ## What is the link to the Apache JIRA
   https://issues.apache.org/jira/browse/HDDS-5211
   
   ## How was this patch tested?
   Patch was tested in 2 ways, 
   
   1. Unit test `TestGrpcOzoneManagerServer`:
   Tests invoking Om gRPC service - creating gRPC server channel invoking grpc service to service OzoneManagerProtocol requests and tearing down service.
   `$ cd hadoop-ozone/ozone-manager`
   `$ mvn -Dtest=TestGrpcOzoneManagerServer test`
   
   ```
   [INFO]  T E S T S
   [INFO] -------------------------------------------------------
   [INFO] Running org.apache.hadoop.ozone.om.TestGrpcOzoneManagerServer
   [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.067 s - in org.apache.hadoop.ozone.om.TestGrpcOzoneManagerServer
   [INFO] 
   [INFO] Results:
   [INFO] 
   [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
   ```
   
   2. Manual testing through configuring `ozone-site.xml `to enable (true)/ disable (false) ozone-manager Grpc server service through property   
   ```
   <property>
       <name>ozone.om.s3.grpc.server_enabled</name>
       <value>true</value>
     </property>
   ```
   Ensuring that gRPC server is started by OM when enabled and not started when disabled though log4j logs.
   eg. 
   `INFO  om.GrpcOzoneManagerServer (GrpcOzoneManagerServer.java:start(61)) - GrpcOzoneManagerServer is started using port 8981
   `
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r703833743



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +
+        "processing s3g client submit request");
+    AtomicInteger callCount = new AtomicInteger(0);
+    try {
+      // need to look into handling the error path, trapping exception

Review comment:
       Why not include the error handling as part of this PR?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r703862877



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/GrpcOzoneManagerServer.java
##########
@@ -0,0 +1,97 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import java.io.IOException;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.hadoop.hdds.conf.Config;
+import org.apache.hadoop.hdds.conf.ConfigGroup;
+import org.apache.hadoop.hdds.conf.ConfigTag;
+import org.apache.hadoop.ozone.OzoneConsts;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import io.grpc.Server;
+import io.grpc.netty.NettyServerBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Separated network server for gRPC transport OzoneManagerService s3g->OM.
+ */
+public class GrpcOzoneManagerServer {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(GrpcOzoneManagerServer.class);
+
+  private Server server;
+  private final String host = "0.0.0.0";
+  private int port = 8981;
+
+  public GrpcOzoneManagerServer(GrpcOzoneManagerServerConfig omServerConfig,
+                                OzoneManagerProtocolServerSideTranslatorPB
+                                    omTranslator) {
+    this.port = omServerConfig.getPort();
+    init(omTranslator);
+  }
+
+  public void init(OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    NettyServerBuilder nettyServerBuilder = NettyServerBuilder.forPort(port)
+        .maxInboundMessageSize(OzoneConsts.OZONE_SCM_CHUNK_MAX_SIZE)
+        .addService(new OzoneManagerServiceGrpc(omTranslator));
+
+    server = nettyServerBuilder.build();
+  }
+
+  public void start() throws IOException {
+    server.start();
+    LOG.info("{} is started using port {}", getClass().getSimpleName(),
+        server.getPort());
+    port = server.getPort();
+  }
+
+  public void stop() {
+    try {
+      server.shutdown().awaitTermination(10L, TimeUnit.SECONDS);
+    } catch (InterruptedException ex) {
+      LOG.warn("{} couldn't be stopped gracefully", getClass().getSimpleName());
+    }
+  }
+
+  public int getPort() {
+    return port; }

Review comment:
       Not sure if the code format check should catch this but looks odd.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r703860960



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/GrpcOzoneManagerServer.java
##########
@@ -0,0 +1,97 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import java.io.IOException;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.hadoop.hdds.conf.Config;
+import org.apache.hadoop.hdds.conf.ConfigGroup;
+import org.apache.hadoop.hdds.conf.ConfigTag;
+import org.apache.hadoop.ozone.OzoneConsts;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import io.grpc.Server;
+import io.grpc.netty.NettyServerBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Separated network server for gRPC transport OzoneManagerService s3g->OM.
+ */
+public class GrpcOzoneManagerServer {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(GrpcOzoneManagerServer.class);
+
+  private Server server;
+  private final String host = "0.0.0.0";

Review comment:
       This is not being used so far.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] swagle merged pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
swagle merged pull request #2601:
URL: https://github.com/apache/ozone/pull/2601


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] neils-dev commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
neils-dev commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r704725662



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +
+        "processing s3g client submit request");
+    AtomicInteger callCount = new AtomicInteger(0);
+    try {
+      // need to look into handling the error path, trapping exception
+      // will be generating OmResponse with status fail & OmException shortly
+      org.apache.hadoop.ipc.Server.getCurCall().set(new Server.Call(1,

Review comment:
       Thanks @kerneltime.  The Server.Call is necessary for processing each `OMRequest` through the ratis transactions and holds caller thread info such as context, callerid.  We don't rely on this for processing requests however the ratis `OzoneManagerRatisServer` requires a `Server` class with the thread context when creating a ratisclientrequest, `createWriteRaftClientRequest`  (Server.getClientId, Server.getCallId).  To satisfy this we use Server.Call to create the instance needed to process requests through ratis/Raft.  Here in creating the thread caller Server.Call, we set the retry count with the atomic integer variable, and importantly the ClientId with a random number.  




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r703861384



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/GrpcOzoneManagerServer.java
##########
@@ -0,0 +1,97 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import java.io.IOException;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.hadoop.hdds.conf.Config;
+import org.apache.hadoop.hdds.conf.ConfigGroup;
+import org.apache.hadoop.hdds.conf.ConfigTag;
+import org.apache.hadoop.ozone.OzoneConsts;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import io.grpc.Server;
+import io.grpc.netty.NettyServerBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Separated network server for gRPC transport OzoneManagerService s3g->OM.
+ */
+public class GrpcOzoneManagerServer {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(GrpcOzoneManagerServer.class);
+
+  private Server server;
+  private final String host = "0.0.0.0";
+  private int port = 8981;
+
+  public GrpcOzoneManagerServer(GrpcOzoneManagerServerConfig omServerConfig,
+                                OzoneManagerProtocolServerSideTranslatorPB
+                                    omTranslator) {
+    this.port = omServerConfig.getPort();
+    init(omTranslator);
+  }
+
+  public void init(OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    NettyServerBuilder nettyServerBuilder = NettyServerBuilder.forPort(port)
+        .maxInboundMessageSize(OzoneConsts.OZONE_SCM_CHUNK_MAX_SIZE)
+        .addService(new OzoneManagerServiceGrpc(omTranslator));
+
+    server = nettyServerBuilder.build();
+  }
+
+  public void start() throws IOException {
+    server.start();
+    LOG.info("{} is started using port {}", getClass().getSimpleName(),
+        server.getPort());
+    port = server.getPort();
+  }
+
+  public void stop() {
+    try {
+      server.shutdown().awaitTermination(10L, TimeUnit.SECONDS);

Review comment:
       Add a `info` log on shutdown.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r704766167



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +
+        "processing s3g client submit request");
+    AtomicInteger callCount = new AtomicInteger(0);
+    try {
+      // need to look into handling the error path, trapping exception
+      // will be generating OmResponse with status fail & OmException shortly
+      org.apache.hadoop.ipc.Server.getCurCall().set(new Server.Call(1,

Review comment:
       Thank you for the pointer @neils-dev I took a look at the use of the thread local Call. Ratis does not explicitly requires the hadoop IPC based `Server` but OM is currently using it to create requests. We should check how the callId is used by Ratis and it they need to serialized between the GRPC based submitRequest and Hadoop IPC based requests. 
   Please add comments here to explain why this is done and what we need to test as a TODO.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r703837700



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +
+        "processing s3g client submit request");
+    AtomicInteger callCount = new AtomicInteger(0);
+    try {
+      // need to look into handling the error path, trapping exception
+      // will be generating OmResponse with status fail & OmException shortly
+      org.apache.hadoop.ipc.Server.getCurCall().set(new Server.Call(1,

Review comment:
       I need to look into how we use this, but incrementing hadoop IPC thread local info seems out of place. Can you explain a bit more?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] neils-dev commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
neils-dev commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r704822394



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/GrpcOzoneManagerServer.java
##########
@@ -0,0 +1,97 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import java.io.IOException;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.hadoop.hdds.conf.Config;
+import org.apache.hadoop.hdds.conf.ConfigGroup;
+import org.apache.hadoop.hdds.conf.ConfigTag;
+import org.apache.hadoop.ozone.OzoneConsts;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import io.grpc.Server;
+import io.grpc.netty.NettyServerBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Separated network server for gRPC transport OzoneManagerService s3g->OM.
+ */
+public class GrpcOzoneManagerServer {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(GrpcOzoneManagerServer.class);
+
+  private Server server;
+  private final String host = "0.0.0.0";

Review comment:
       @kerneltime, thanks for reviewing and for your comments.  Removing unnecessary host String variable, not used.  Changes are in latest commit.

##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/GrpcOzoneManagerServer.java
##########
@@ -0,0 +1,97 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import java.io.IOException;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.hadoop.hdds.conf.Config;
+import org.apache.hadoop.hdds.conf.ConfigGroup;
+import org.apache.hadoop.hdds.conf.ConfigTag;
+import org.apache.hadoop.ozone.OzoneConsts;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import io.grpc.Server;
+import io.grpc.netty.NettyServerBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Separated network server for gRPC transport OzoneManagerService s3g->OM.
+ */
+public class GrpcOzoneManagerServer {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(GrpcOzoneManagerServer.class);
+
+  private Server server;
+  private final String host = "0.0.0.0";
+  private int port = 8981;
+
+  public GrpcOzoneManagerServer(GrpcOzoneManagerServerConfig omServerConfig,
+                                OzoneManagerProtocolServerSideTranslatorPB
+                                    omTranslator) {
+    this.port = omServerConfig.getPort();
+    init(omTranslator);
+  }
+
+  public void init(OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    NettyServerBuilder nettyServerBuilder = NettyServerBuilder.forPort(port)
+        .maxInboundMessageSize(OzoneConsts.OZONE_SCM_CHUNK_MAX_SIZE)
+        .addService(new OzoneManagerServiceGrpc(omTranslator));
+
+    server = nettyServerBuilder.build();
+  }
+
+  public void start() throws IOException {
+    server.start();
+    LOG.info("{} is started using port {}", getClass().getSimpleName(),
+        server.getPort());
+    port = server.getPort();
+  }
+
+  public void stop() {
+    try {
+      server.shutdown().awaitTermination(10L, TimeUnit.SECONDS);

Review comment:
       Added info log to shutdown indicating server stopped; on failure raise exception and error logged as warn.

##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/GrpcOzoneManagerServer.java
##########
@@ -0,0 +1,97 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import java.io.IOException;
+import java.util.concurrent.TimeUnit;
+
+import org.apache.hadoop.hdds.conf.Config;
+import org.apache.hadoop.hdds.conf.ConfigGroup;
+import org.apache.hadoop.hdds.conf.ConfigTag;
+import org.apache.hadoop.ozone.OzoneConsts;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import io.grpc.Server;
+import io.grpc.netty.NettyServerBuilder;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Separated network server for gRPC transport OzoneManagerService s3g->OM.
+ */
+public class GrpcOzoneManagerServer {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(GrpcOzoneManagerServer.class);
+
+  private Server server;
+  private final String host = "0.0.0.0";
+  private int port = 8981;
+
+  public GrpcOzoneManagerServer(GrpcOzoneManagerServerConfig omServerConfig,
+                                OzoneManagerProtocolServerSideTranslatorPB
+                                    omTranslator) {
+    this.port = omServerConfig.getPort();
+    init(omTranslator);
+  }
+
+  public void init(OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    NettyServerBuilder nettyServerBuilder = NettyServerBuilder.forPort(port)
+        .maxInboundMessageSize(OzoneConsts.OZONE_SCM_CHUNK_MAX_SIZE)
+        .addService(new OzoneManagerServiceGrpc(omTranslator));
+
+    server = nettyServerBuilder.build();
+  }
+
+  public void start() throws IOException {
+    server.start();
+    LOG.info("{} is started using port {}", getClass().getSimpleName(),
+        server.getPort());
+    port = server.getPort();
+  }
+
+  public void stop() {
+    try {
+      server.shutdown().awaitTermination(10L, TimeUnit.SECONDS);
+    } catch (InterruptedException ex) {
+      LOG.warn("{} couldn't be stopped gracefully", getClass().getSimpleName());
+    }
+  }
+
+  public int getPort() {
+    return port; }

Review comment:
       cleaned up (typo backspace?).

##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +

Review comment:
       Added the request command type name to debug log for OMRequest to aid in debugging processed requests.  Full displaying full OMRequest may be too verbose. 

##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +
+        "processing s3g client submit request");
+    AtomicInteger callCount = new AtomicInteger(0);
+    try {
+      // need to look into handling the error path, trapping exception

Review comment:
       Added handling exception for processing OMRequest.  Error handling through returning an error OMResponse with success:false and message detailing exception.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#issuecomment-915647509


   LGTM


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] kerneltime commented on a change in pull request #2601: HDDS-5211. Start OM Grpc server as part of the OM bootstrap

Posted by GitBox <gi...@apache.org>.
kerneltime commented on a change in pull request #2601:
URL: https://github.com/apache/ozone/pull/2601#discussion_r703832910



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManagerServiceGrpc.java
##########
@@ -0,0 +1,78 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om;
+
+import com.google.protobuf.RpcController;
+import com.google.protobuf.ServiceException;
+import org.apache.hadoop.ipc.ClientId;
+import org.apache.hadoop.ipc.RPC;
+import org.apache.hadoop.ipc.Server;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerServiceGrpc.OzoneManagerServiceImplBase;
+import org.apache.hadoop.ozone.protocolPB.OzoneManagerProtocolServerSideTranslatorPB;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMResponse;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * Grpc Service for handling S3 gateway OzoneManagerProtocol client requests.
+ */
+public class OzoneManagerServiceGrpc extends OzoneManagerServiceImplBase {
+  private static final Logger LOG =
+      LoggerFactory.getLogger(OzoneManagerServiceGrpc.class);
+  /**
+   * RpcController is not used and hence is set to null.
+   */
+  private static final RpcController NULL_RPC_CONTROLLER = null;
+  private OzoneManagerProtocolServerSideTranslatorPB omTranslator;
+
+  OzoneManagerServiceGrpc(
+      OzoneManagerProtocolServerSideTranslatorPB omTranslator) {
+    this.omTranslator = omTranslator;
+  }
+
+  @Override
+  public void submitRequest(org.apache.hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.
+                                OMRequest request,
+                            io.grpc.stub.StreamObserver<org.apache.
+                                hadoop.ozone.protocol.proto.
+                                OzoneManagerProtocolProtos.OMResponse>
+                                responseObserver) {
+    LOG.debug("GrpcOzoneManagerServer: OzoneManagerServiceImplBase " +

Review comment:
       Maybe include the request details as well in the debug log?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org