hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "rangjiaheng (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-8435) NullPointerException when client first time connect to Yarn Router
Date Wed, 20 Jun 2018 05:01:00 GMT

    [ https://issues.apache.org/jira/browse/YARN-8435?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16517802#comment-16517802

rangjiaheng commented on YARN-8435:

Thanks [~giovanni.fumarola] for review, I can reproduce the exception in trunk code using
the following test case:

public void testPipelineConcurrent() throws InterruptedException {
  final String user = "yarn";

  class ClientThread extends Thread {
    @Override public void run() {
      try {
      } catch (IOException | InterruptedException e) {

    private void pipeline() throws IOException, InterruptedException {
          .doAs(new PrivilegedExceptionAction<ClientRequestInterceptor>() {
            @Override public ClientRequestInterceptor run() throws Exception {
              RequestInterceptorChainWrapper pipeline =
              ClientRequestInterceptor root = pipeline.getRootInterceptor();
              System.out.println("init new interceptor for user " + user);
              return root;

  new ClientThread().start();
  new ClientThread().start();

Which out put :

Exception in thread "Thread-56" java.lang.NullPointerException
at org.apache.hadoop.yarn.server.router.clientrm.TestRouterClientRMService$1ClientThread$1.run(TestRouterClientRMService.java:231)
at org.apache.hadoop.yarn.server.router.clientrm.TestRouterClientRMService$1ClientThread$1.run(TestRouterClientRMService.java:227)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:422)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1683)
at org.apache.hadoop.yarn.server.router.clientrm.TestRouterClientRMService$1ClientThread.pipeline(TestRouterClientRMService.java:227)
at org.apache.hadoop.yarn.server.router.clientrm.TestRouterClientRMService$1ClientThread.run(TestRouterClientRMService.java:219)

YARN-8435.v1.patch can pass this test case.


However, this test case code is not beautiful, should I put the test case with YARN-8435.patch
together ?


> NullPointerException when client first time connect to Yarn Router
> ------------------------------------------------------------------
>                 Key: YARN-8435
>                 URL: https://issues.apache.org/jira/browse/YARN-8435
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: router
>    Affects Versions: 2.9.0, 3.0.2
>            Reporter: rangjiaheng
>            Priority: Critical
>         Attachments: YARN-8435.v1.patch
> When Two client process (with the same user name and the same hostname) begin to connect
to yarn router at the same time, to submit application, kill application, ... and so on,
then a java.lang.NullPointerException may throws from yarn router.

This message was sent by Atlassian JIRA

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

View raw message