Description
When tasks are interrupted/killed in the middle of the job in LLAP, LlapDaemonExecutorMetrics.updateThreadMetrics could end up throwing NPE.
java.lang.NullPointerException at org.apache.hadoop.hive.llap.metrics.LlapDaemonExecutorMetrics.updateThreadMetrics(LlapDaemonExecutorMetrics.java:307) ~[hive-llap-server-2.2.0-SNAPSHOT.jar:2.2.0-SNAPSHOT] at org.apache.hadoop.hive.llap.metrics.LlapDaemonExecutorMetrics.getExecutorStats(LlapDaemonExecutorMetrics.java:269) ~[hive-llap-server-2.2.0-SNAPSHOT.jar:2.2.0-SNAPSHOT] at org.apache.hadoop.hive.llap.metrics.LlapDaemonExecutorMetrics.getMetrics(LlapDaemonExecutorMetrics.java:187) ~[hive-llap-server-2.2.0-SNAPSHOT.jar:2.2.0-SNAPSHOT] at org.apache.hadoop.metrics2.impl.MetricsSourceAdapter.getMetrics(MetricsSourceAdapter.java:194) ~[hadoop-common-2.7.1.jar:?] at org.apache.hadoop.metrics2.impl.MetricsSourceAdapter.updateJmxCache(MetricsSourceAdapter.java:172) ~[hadoop-common-2.7.1.jar:?] at org.apache.hadoop.metrics2.impl.MetricsSourceAdapter.getMBeanInfo(MetricsSourceAdapter.java:151) ~[hadoop-common-2.7.1.jar:?] at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.getMBeanInfo(DefaultMBeanServerInterceptor.java:1378) ~[?:1.8.0_77] at com.sun.jmx.mbeanserver.JmxMBeanServer.getMBeanInfo(JmxMBeanServer.java:920) ~[?:1.8.0_77] at org.apache.hive.http.JMXJsonServlet.listBeans(JMXJsonServlet.java:228) ~[hive-exec-2.2.0-SNAPSHOT.jar:2.2.0-SNAPSHOT] at org.apache.hive.http.JMXJsonServlet.doGet(JMXJsonServlet.java:194) ~[hive-exec-2.2.0-SNAPSHOT.jar:2.2.0-SNAPSHOT]