Bläddra i källkod

PR1126 [hive] Retrieve the proper LLAP session (#1126)

added llap editor type to session lookup filter by type

Co-authored-by: Theyaa Matti <theyaa.matti@gm.com>
Co-authored-by: Romain Rigaux <romain.rigaux@gmail.com>
theyaa 5 år sedan
förälder
incheckning
1244b9db02
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      desktop/libs/notebook/src/notebook/connectors/hiveserver2.py

+ 1 - 1
desktop/libs/notebook/src/notebook/connectors/hiveserver2.py

@@ -672,7 +672,7 @@ DROP TABLE IF EXISTS `%(table)s`;
     if session:
       session_id = session.get('id')
       if session_id:
-        filters = {'id': session_id, 'application': 'beeswax' if type == 'hive' else type}
+        filters = {'id': session_id, 'application': 'beeswax' if type == 'hive' or type == 'llap' else type}
         if not is_admin(self.user):
           filters['owner'] = self.user
         return Session.objects.get(**filters)