Эх сурвалжийг харах

HUE-8564 [useradmin] Fix last activity update for jobbrowser oozie logs

Ying Chen 7 жил өмнө
parent
commit
e15500911e

+ 3 - 2
apps/useradmin/src/useradmin/middleware.py

@@ -92,9 +92,10 @@ class LastActivityMiddleware(object):
 
     # Save last activity for user except when polling
     if not (request.path.strip('/') == 'notebook/api/check_status') \
-        and not (request.path.strip('/') == 'jobbrowser/api/jobs') \
+        and not (request.path.strip('/').startswith('jobbrowser/api/job')) \
         and not (request.path.strip('/') == 'jobbrowser/jobs' and request.POST.get('format') == 'json') \
-        and not (request.path.strip('/') == 'desktop/debug/is_idle'):
+        and not (request.path.strip('/') == 'desktop/debug/is_idle') \
+        and not (request.path.strip('/').startswith('oozie/list_oozie_')):
       try:
         profile.last_activity = datetime.now()
         profile.save()