Add the option to disable a physical library
Introduction
At the moment it's only possible to disable logical libraries, not physical libraries.
This works the following way:
- To enable/disable run
cta-admin ll ch --name/-n <logical_library_name> --disabled/-d "true"|"false"
. - To check the disabled state run
cta-admin --json ll ls
and check the field"isDisabled"
(and"disabledReadon"
). - Alternatively run
cta-admin --json dr ls
and check the field"logicalLibraryDisabled"
.
The state is stored in the CTA Catalogue, using the field IS_DISABLED
of the LOGICAL_LIBRARY
table.
Problem
As shown in https://gitlab.cern.ch/cta/operations/-/issues/1418, there is currently no way mark a physical library as disabled.
This means that we need to disable all logical libraries, one by one, if we want to perform work on a physical library.
Furthermore, operational tools have no visibility over this.
Discussed solution
This was discussed on https://gitlab.cern.ch/cta/operations/-/issues/1418#note_8066764.
Add new functionality to mark physical libraries as disabled:
- Add new
IS_DISABLED
andDISABLED_REASON
columns to thePHYSICAL_LIBRARY
table (CTA catalogue schema change). - Add a new
"isDisabled": true|false
field to thecta-admin --json pl ls
command, and a similar column incta-admin pl ls
. - Add a new
"disabledReason": <value>
field to thecta-admin --json pl ls
command. - Add a new
"physicalLibraryDisabled": true|false
to thecta-admin --json dr ls
command.