Project

General

Profile

Actions

Bug #43165

closed

Feature #40907: mgr/dashboard: REST API improvements

mgr/dashboard: remove `/api/orchestrator/<resource>` endpoints if possible

Added by Kiefer Chang over 4 years ago. Updated about 3 years ago.

Status:
Resolved
Priority:
High
Assignee:
Category:
General - Back-end
Target version:
% Done:

50%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

We are using `/api/orchestrator/<resource>` endpoints to expose information from orchestrator to users.
In order to make the API much RESTful, we should try to minimize the use of the endpoints and integrate those orchestrator calls into suitable existing endpoints.
See these discussions for more information:

Some thoughts of improvement:

/api/orchestrator/status

Keep it or move to /api/summary.

/api/orchestrator/inventory

We use this endpoint to expose devices that belonged to all hosts or one host.

/api/orchestrator/inventory
/api/orchestrator/inventory?hostname=node1

Which might be moved to:

/api/host/node1/devices
The difficulties here are:
  • /host/<hostname>/devices endpoints is already used for devices reported from Ceph. Which needs further integration.
  • There is a page Cluster -> Inventory that lists all devices on all hosts. To keep that page, we need to
    • forkjoin or merge individual calls for each host
    • Create a special endpoint to return all inventory devices, which is the reason I choose /api/orchestrator/inventory before.

/api/orchestrator/service (Moved to /api/services)

May just rename to /api/service.

/api/orchestrator/osd (Removed)

Integrate into /api/osd.

Actions

Also available in: Atom PDF