[jira] [Commented] (HDFS-15912) Allow ProtobufRpcEngine to be extensible

2021-04-30 Thread Konstantin Shvachko (Jira)


[ 
https://issues.apache.org/jira/browse/HDFS-15912?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17337546#comment-17337546
 ] 

Konstantin Shvachko commented on HDFS-15912:


Since all changes are in {{hadoop-common}} this should be HADOOP-* jira, rather 
than HDFS-.
Could you please move it to the right jira project to adjust the visibility for 
the right audience.

About the change itself.
# There are some [checkstyle 
warnings|https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-2905/1/artifact/out/results-checkstyle-hadoop-common-project_hadoop-common.txt],
 which are actually right. It is perfectly fine for methods to be protected , 
but not for the members. A better way is to keep them private and provide 
get/setters. For those that are really needed.
# I see some white space change, like a blank line with spaces.

> Allow ProtobufRpcEngine to be extensible
> 
>
> Key: HDFS-15912
> URL: https://issues.apache.org/jira/browse/HDFS-15912
> Project: Hadoop HDFS
>  Issue Type: Improvement
>  Components: hdfs
>Reporter: Hector Sandoval Chaverri
>Assignee: Hector Sandoval Chaverri
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 1h
>  Remaining Estimate: 0h
>
> The ProtobufRpcEngine class doesn't allow for new RpcEngine implementations 
> to extend some of its inner classes (e.g. Invoker and 
> Server.ProtoBufRpcInvoker). Also, some of its methods are long enough such 
> that overriding them would result in a lot of code duplication (e.g. 
> Invoker#invoke and Server.ProtoBufRpcInvoker#call).
> When implementing a new RpcEngine, it would be helpful to reuse most of the 
> code already in ProtobufRpcEngine. This would allow new fields to be added to 
> the RPC header or message with minimal code changes.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

-
To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org



[jira] [Commented] (HDFS-15912) Allow ProtobufRpcEngine to be extensible

2021-04-13 Thread Hector Sandoval Chaverri (Jira)


[ 
https://issues.apache.org/jira/browse/HDFS-15912?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17320603#comment-17320603
 ] 

Hector Sandoval Chaverri commented on HDFS-15912:
-

The following changes are proposed on ProtobufRpcEngine and ProtobufRpcEngine2:
 # Change Invoker class, its constructors and fields from private to protected.
 # Move creation of RpcProtobufRequest object out of the Invoker#invoke method 
and into a new Invoker#constructRpcRequest method that can be overriden.
 # Create overload of the Server.ProtoBufRpcInvoker#call method that can be 
invoked after the RPC request is obtained. 

> Allow ProtobufRpcEngine to be extensible
> 
>
> Key: HDFS-15912
> URL: https://issues.apache.org/jira/browse/HDFS-15912
> Project: Hadoop HDFS
>  Issue Type: Improvement
>  Components: hdfs
>Reporter: Hector Sandoval Chaverri
>Assignee: Hector Sandoval Chaverri
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 1h
>  Remaining Estimate: 0h
>
> The ProtobufRpcEngine class doesn't allow for new RpcEngine implementations 
> to extend some of its inner classes (e.g. Invoker and 
> Server.ProtoBufRpcInvoker). Also, some of its methods are long enough such 
> that overriding them would result in a lot of code duplication (e.g. 
> Invoker#invoke and Server.ProtoBufRpcInvoker#call).
> When implementing a new RpcEngine, it would be helpful to reuse most of the 
> code already in ProtobufRpcEngine. This would allow new fields to be added to 
> the RPC header or message with minimal code changes.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

-
To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org