Browse Source

HUE-8302 [jobbrowser] Failed to fetch logs for Spark jobs (#690)

Ivan Dzikovsky 7 years ago
parent
commit
429799a068

+ 1 - 1
apps/jobbrowser/src/jobbrowser/yarn_models.py

@@ -139,7 +139,7 @@ class SparkJob(Application):
         self._client.set_kerberos_auth()
 
       self._client.set_verify(yarn_cluster.SSL_CERT_CA_VERIFY.get())
-      actual_url = self._execute(self._root.resolve_redirect_url())
+      actual_url = self._execute(self._root.resolve_redirect_url)
 
       if actual_url.strip('/').split('/')[-1] == 'jobs':
         actual_url = actual_url.strip('/').replace('jobs', '')

+ 1 - 0
desktop/libs/hadoop/src/hadoop/yarn/spark_history_server_api.py

@@ -160,6 +160,7 @@ class SparkHistoryServerApi(object):
     return log
 
   def get_executors_loglinks(self, job):
+    executor = None
     if job.metrics and 'executors' in job.metrics and job.metrics['executors']:
       executors = [executor for executor in job.metrics['executors'] if executor[0] == 'driver']  # look up driver executor
       if not executors: