distcloud/distributedcloud/dcmanager/api
Li Zhu 00a3e50e71 Display prestage status and versions in subcloud list
The prestage release can be either the previous or current release for
a subcloud. Checking the prestage release individually on thousands of
subclouds is impractical. Therefore, a new column called "prestage
versions" is added to the output of the "dcmanager subcloud list'
command. Besides, decoupling prestage status from deploy status.

Test plan:
PASS: Successful subcloud prestage with specified 22.12 or 23.09
      release, and verified the correct "prestage versions" output of
      the "dcmanager subcloud list" command.
PASS: Successful prestage strategy with specified 22.12 or 23.09
      release, and verified the correct "prestage versions" output of
      the "dcmanager subcloud list".
PASS: Verified the "prestage status" at each prestage stage.
PASS: Verified that the 'deploy status' was updated to 'complete' after
      upgrading the system controller from version 22.12 to 23.09.
      This verification was performed specifically for those subclouds
      that had a 'prestage-complete' deploy status with the previous
      22.12 system controller. The new columns, "perstage status" and
      "prestage versions", were empty after upgrading.

Depends-on:
https://review.opendev.org/c/starlingx/ansible-playbooks/+/904546

Story: 2010611
Task: 49367

Change-Id: Ica65b1e2e8e44b96352e7d45439a2e7a9063f7c9
Signed-off-by: lzhu1 <li.zhu@windriver.com>
2024-01-26 14:09:19 -05:00
..
controllers Display prestage status and versions in subcloud list 2024-01-26 14:09:19 -05:00
policies Update tox pylint/pep8 for dcmanager 2024-01-18 21:51:25 +00:00
README.rst Move content to subdir to support relocated packaging 2019-11-04 13:57:02 -05:00
__init__.py Move content to subdir to support relocated packaging 2019-11-04 13:57:02 -05:00
api_config.py Implement access control for DC API 2022-09-22 18:26:35 -03:00
app.py Update tox pylint/pep8 for dcmanager 2024-01-18 21:51:25 +00:00
policy.py Update tox pylint/pep8 for dcmanager 2024-01-18 21:51:25 +00:00

README.rst

api

DC Manager API is Web Server Gateway Interface (WSGI) application to receive and process API calls, including keystonemiddleware to do the authentication, parameter check and validation, convert API calls to job rpc message, and then send the job to DC Manager Manager through the queue. If the job will be processed by DC Manager Manager in synchronous way, the DC Manager API will wait for the response from the DC Manager Manager. Otherwise, the DC Manager API will send response to the API caller first, and then send the job to DC Manager Manager in asynchronous way.

Multiple DC Manager API could run in parallel, and also can work in multi-worker mode.

Multiple DC Manager API will be designed and run in stateless mode, persistent data will be accessed (read and write) from the DC Manager Database through the DAL module.

Setup and encapsulate the API WSGI app

app.py:

Setup and encapsulate the API WSGI app, including integrate the keystonemiddleware app

api_config.py:

API configuration loading and init

enforcer.py

Enforces policies on the version2 APIs