Project

General

Profile

Actions

Bug #20449

open

Background refresh tasks of "all processes" issues

Added by Peter Amstutz about 1 month ago. Updated about 5 hours ago.

Status:
In Progress
Priority:
Normal
Assigned To:
Category:
Workbench2
Target version:
Start date:
06/01/2023
Due date:
% Done:

0%

Estimated time:
(Total: 0.00 h)
Story points:
-
Release relationship:
Auto

Description

Workbench 2 makes queries in the background to automatically refresh the display.

However, there are two issues:

a) It seems to be continuously refreshing the "All Processes" list even when the user is not at that panel, which is wasteful and slows down the app (and possibly is a memory leak)

b) More generally, the current behavior is that the top red bar cycles any time there is an outstanding AJAX request -- when the cluster is moderately busy, this causes the red spinner to just spin constantly, which makes it useless for the intended behavior of informing the user if the navigation action they performed has completed loading.

The spinner should only activate in response to deliberate user interactions such as navigation, paging, hitting "refresh" etc.

edit:

On further observation, this doesn't happen all the time. When it does happen it gets stuck in a tight loop of reloading containers and container requests. This definitely seems like a bug.

edit 2:

Looking at src/websocket/websocket.ts it looks like it fires off REQUEST_ITEMS to refresh for both the subprocesses panel and all processes panel any time it sees a create or update message related to a container request or container. It doesn't care what is actually on screen. So this should

  1. Only refresh all processes when that panel is in front
  2. Only refresh subprocesses when the visible process panel is the parent of the container that was updated
  3. Debounce refreshes so they are limited to once every 5 or 10 seconds

The odd thing is that I would expect this to be more of a problem but right now I'm looking at a cluster that is running a bunch of containers and nothing is being reloaded, which makes me question if websockets is actually working.

edit 3:

Tom suggested that maybe websockets isn't consistently setting its subscription to events when the application starts based on what route you are at, so that might explain why sometimes this happens and sometimes it doesn't.


Subtasks 1 (1 open0 closed)

Task #20502: Review 20449-processes-refreshIn Progress06/01/2023

Actions

Related issues

Related to Arvados - Bug #20507: Fix websocket service or get rid of itNew

Actions
Actions #1

Updated by Peter Amstutz about 1 month ago

  • Description updated (diff)
Actions #3

Updated by Peter Amstutz about 1 month ago

  • Target version changed from To be groomed to Development 2023-05-10 sprint
Actions #4

Updated by Peter Amstutz about 1 month ago

  • Description updated (diff)
  • Subject changed from Background refresh tasks should not spin the bar to Background refresh tasks of "all processes" issues
Actions #5

Updated by Peter Amstutz about 1 month ago

  • Release set to 63
  • Assigned To set to Stephen Smith
Actions #6

Updated by Peter Amstutz 27 days ago

  • Description updated (diff)
Actions #7

Updated by Peter Amstutz 23 days ago

  • Target version changed from Development 2023-05-10 sprint to Development 2023-05-24 sprint
Actions #8

Updated by Peter Amstutz 22 days ago

  • Description updated (diff)
Actions #9

Updated by Peter Amstutz 22 days ago

  • Description updated (diff)
Actions #10

Updated by Peter Amstutz 22 days ago

  • Related to Bug #20507: Fix websocket service or get rid of it added
Actions #11

Updated by Peter Amstutz 22 days ago

  • Release deleted (63)
  • Target version changed from Development 2023-05-24 sprint to To be groomed
Actions #12

Updated by Peter Amstutz 22 days ago

  • Assigned To deleted (Stephen Smith)
Actions #13

Updated by Peter Amstutz 1 day ago

  • Description updated (diff)
Actions #14

Updated by Peter Amstutz about 7 hours ago

  • Target version changed from To be groomed to Development 2023-06-07
  • Assigned To set to Peter Amstutz
Actions #15

Updated by Peter Amstutz about 5 hours ago

20449-processes-refresh @ arvados-workbench2|3a9f6442080843c97737aae74608cb2d188be1da

Check that we're on a process page or all processes and that the event is possibly relevant to the current process before reloading to avoid endless background reloading from slowing down the app.

developer-tests-workbench2: #1241

Actions #16

Updated by Peter Amstutz about 5 hours ago

  • Release set to 64
Actions #17

Updated by Peter Amstutz about 5 hours ago

  • Status changed from New to In Progress
Actions

Also available in: Atom PDF