[ https://issues.apache.org/jira/browse/TEZ-4282?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17281328#comment-17281328 ]
Ashutosh Chauhan commented on TEZ-4282: --------------------------------------- +1 > Possible NPE in LocalClient after TEZ-4236 > ------------------------------------------ > > Key: TEZ-4282 > URL: https://issues.apache.org/jira/browse/TEZ-4282 > Project: Apache Tez > Issue Type: Bug > Reporter: László Bodor > Assignee: László Bodor > Priority: Major > Time Spent: 1.5h > Remaining Estimate: 0h > > It can be detected in hive unit tests: > {code} > Caused by: java.lang.NullPointerException > at org.apache.tez.client.LocalClient.getAMStatus(LocalClient.java:406) > at > org.apache.tez.client.TezClient.getAppMasterStatus(TezClient.java:843) > at org.apache.tez.client.TezClient.waitTillReady(TezClient.java:977) > at org.apache.tez.client.TezClient.preWarm(TezClient.java:924) > at org.apache.tez.client.TezClient.preWarm(TezClient.java:879) > at > org.apache.hadoop.hive.ql.exec.tez.TezSessionState.startSessionAndContainers(TezSessionState.java:546) > at > org.apache.hadoop.hive.ql.exec.tez.TezSessionState.openInternal(TezSessionState.java:374) > at > org.apache.hadoop.hive.ql.exec.tez.TezSessionState.open(TezSessionState.java:313) > at > org.apache.hadoop.hive.ql.exec.tez.TezSessionState.open(TezSessionState.java:220) > at > org.apache.hadoop.hive.ql.session.SessionState.start(SessionState.java:711) > {code} > the problem only affects LocalClient, so not a production-level issue, but > unit tests can fail with this problem > the original getAMStatus in FrameworkClient detected the non-readiness of the > AM through the proxy: > {code} > if (proxy == null) { > return TezAppMasterStatus.INITIALIZING; > } > GetAMStatusResponseProto response = > proxy.getAMStatus(null, GetAMStatusRequestProto.newBuilder().build()); > return > DagTypeConverters.convertTezAppMasterStatusFromProto(response.getStatus()); > {code} > a similar solution should go to LocalClient, and only if > isLocalWithoutNetwork is on > {code} > if (clientHandler == null){ > return TezAppMasterStatus.INITIALIZING; > } > return clientHandler.getTezAppMasterStatus(); > {code} -- This message was sent by Atlassian Jira (v8.3.4#803005)