goiri commented on code in PR #5752:
URL: https://github.com/apache/hadoop/pull/5752#discussion_r1237252214


##########
hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/clientrm/DefaultClientRequestInterceptor.java:
##########
@@ -116,16 +120,15 @@ public void init(String userName) {
     final Configuration conf = this.getConf();
     try {
       clientRMProxy =
-          user.doAs(new PrivilegedExceptionAction<ApplicationClientProtocol>() 
{
-            @Override
-            public ApplicationClientProtocol run() throws Exception {
-              return ClientRMProxy.createRMProxy(conf,
-                  ApplicationClientProtocol.class);
-            }
-          });
+          user.doAs((PrivilegedExceptionAction<ApplicationClientProtocol>) () 
->

Review Comment:
   The readability of the same in DefaultRMAdminRequestInterceptor is better.
   I would split the line with the doAs from the lambda.



-- 
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: common-issues-unsubscr...@hadoop.apache.org

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


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

Reply via email to