Project

General

Profile

Actions

action #25766

closed

[tools][sprint 201712.1][bonus] Displaying all Worker status by calling Websocket DBus service in the WebUI list is overkill

Added by EDiGiacinto about 7 years ago. Updated almost 7 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
Start date:
2017-10-04
Due date:
% Done:

0%

Estimated time:

Description

When browsing the WebUI, clicking on "Workers" to get the list triggers an extensive loop call over websocket dbus service, that is performed over all the workers just to check if they are connected and display the result to the user.

This operation is potentially overkill when dealing with large number of workers, since each view of that page, triggers a dbus call for each worker, that yields generally to a O(N*M) complexity where M are the users hitting the page in the same moment and N are the registered workers, without taking in consideration the dbus call dispatch timings.

I think instead we should retrieve the same information in the DB, since it is already holding the necessary information to determine if a worker is up or down.

For reference, the method that is being called is 'connected' in the Worker schema [1] called by 'info' [2] that gets propagated from [3][4]

  1. https://github.com/os-autoinst/openQA/blob/master/lib/OpenQA/Schema/Result/Workers.pm#L157
  2. https://github.com/os-autoinst/openQA/blob/master/lib/OpenQA/Schema/Result/Workers.pm#L190
  3. https://github.com/os-autoinst/openQA/blob/master/lib/OpenQA/WebAPI/Controller/Admin/Workers.pm#L25
  4. https://github.com/os-autoinst/openQA/blob/master/lib/OpenQA/WebAPI/Controller/Admin/Workers.pm#L38

Related issues 2 (0 open2 closed)

Related to openQA Project (public) - coordination #27832: [epic][tools][sprint 201712.2][bonus] Revamping of /admin/workersResolvedEDiGiacinto2017-11-17

Actions
Related to openQA Project (public) - action #19996: [tools][sprint 201712.2] Show only online workers by default on the workers page `/admin/workers`ResolvedEDiGiacinto2017-06-22

Actions
Actions #1

Updated by EDiGiacinto about 7 years ago

  • Subject changed from [tools] Displaying all Worker status in the WebUI list is overkill to [tools] Displaying all Worker status by calling Websocket DBus service in the WebUI list is overkill
Actions #2

Updated by EDiGiacinto about 7 years ago

  • Related to coordination #27832: [epic][tools][sprint 201712.2][bonus] Revamping of /admin/workers added
Actions #3

Updated by EDiGiacinto about 7 years ago

  • Related to action #19996: [tools][sprint 201712.2] Show only online workers by default on the workers page `/admin/workers` added
Actions #4

Updated by EDiGiacinto about 7 years ago

  • Assignee set to EDiGiacinto
Actions #5

Updated by EDiGiacinto about 7 years ago

  • Status changed from New to Resolved
Actions #6

Updated by EDiGiacinto almost 7 years ago

  • Subject changed from [tools] Displaying all Worker status by calling Websocket DBus service in the WebUI list is overkill to [tools][sprint 201712.2][bonus] Displaying all Worker status by calling Websocket DBus service in the WebUI list is overkill
  • Target version changed from future to Current Sprint
Actions #7

Updated by szarate almost 7 years ago

  • Subject changed from [tools][sprint 201712.2][bonus] Displaying all Worker status by calling Websocket DBus service in the WebUI list is overkill to [tools][sprint 201712.1][bonus] Displaying all Worker status by calling Websocket DBus service in the WebUI list is overkill
Actions #8

Updated by szarate almost 7 years ago

  • Target version changed from Current Sprint to Done
Actions

Also available in: Atom PDF