xref: /openbmc/bmcweb/features/redfish/include/registries/composition_message_registry.hpp (revision 40e9b92ec19acffb46f83a6e55b18974da5d708e)
1*40e9b92eSEd Tanous // SPDX-License-Identifier: Apache-2.0
2*40e9b92eSEd Tanous // SPDX-FileCopyrightText: Copyright OpenBMC Authors
3665e7602SGunnar Mills #pragma once
4665e7602SGunnar Mills /****************************************************************
5665e7602SGunnar Mills  *                 READ THIS WARNING FIRST
6665e7602SGunnar Mills  * This is an auto-generated header which contains definitions
7665e7602SGunnar Mills  * for Redfish DMTF defined messages.
8665e7602SGunnar Mills  * DO NOT modify this registry outside of running the
9665e7602SGunnar Mills  * parse_registries.py script.  The definitions contained within
10665e7602SGunnar Mills  * this file are owned by DMTF.  Any modifications to these files
11665e7602SGunnar Mills  * should be first pushed to the relevant registry in the DMTF
12665e7602SGunnar Mills  * github organization.
13665e7602SGunnar Mills  ***************************************************************/
14665e7602SGunnar Mills #include "registries.hpp"
15665e7602SGunnar Mills 
16665e7602SGunnar Mills #include <array>
17665e7602SGunnar Mills 
18665e7602SGunnar Mills // clang-format off
19665e7602SGunnar Mills 
20665e7602SGunnar Mills namespace redfish::registries::composition
21665e7602SGunnar Mills {
22665e7602SGunnar Mills const Header header = {
23665e7602SGunnar Mills     "Copyright 2019-2023 DMTF. All rights reserved.",
24665e7602SGunnar Mills     "#MessageRegistry.v1_6_2.MessageRegistry",
2556b81992SEd Tanous     1,
2656b81992SEd Tanous     1,
2756b81992SEd Tanous     2,
28665e7602SGunnar Mills     "Composition Message Registry",
29665e7602SGunnar Mills     "en",
30665e7602SGunnar Mills     "This registry defines the messages for composition related events.",
31665e7602SGunnar Mills     "Composition",
32665e7602SGunnar Mills     "DMTF",
33665e7602SGunnar Mills };
34665e7602SGunnar Mills constexpr const char* url =
35665e7602SGunnar Mills     "https://redfish.dmtf.org/registries/Composition.1.1.2.json";
36665e7602SGunnar Mills 
37665e7602SGunnar Mills constexpr std::array registry =
38665e7602SGunnar Mills {
39665e7602SGunnar Mills     MessageEntry{
40665e7602SGunnar Mills         "ConstrainedResourceAlreadyReserved",
41665e7602SGunnar Mills         {
42665e7602SGunnar Mills             "Indicates that the requested resources are already reserved in response to a constrained composition request.",
43665e7602SGunnar Mills             "The requested resources are reserved under reservation '%1'.",
44665e7602SGunnar Mills             "Critical",
45665e7602SGunnar Mills             1,
46665e7602SGunnar Mills             {
47665e7602SGunnar Mills                 "string",
48665e7602SGunnar Mills             },
49665e7602SGunnar Mills             "Delete the reservation containing the resources and resubmit the request.",
50665e7602SGunnar Mills         }},
51665e7602SGunnar Mills     MessageEntry{
52665e7602SGunnar Mills         "EmptyManifest",
53665e7602SGunnar Mills         {
54665e7602SGunnar Mills             "Indicates that the manifest contains no stanzas or that a stanza in the manifest contains no request.",
55665e7602SGunnar Mills             "The provided manifest is empty or a stanza in the manifest contains no request.",
56665e7602SGunnar Mills             "Warning",
57665e7602SGunnar Mills             0,
58665e7602SGunnar Mills             {},
59665e7602SGunnar Mills             "Provide a request content for the manifest and resubmit.",
60665e7602SGunnar Mills         }},
61665e7602SGunnar Mills     MessageEntry{
62665e7602SGunnar Mills         "IncompatibleZone",
63665e7602SGunnar Mills         {
64665e7602SGunnar Mills             "Indicates that not all referenced resource blocks are in the same resource zone.",
65665e7602SGunnar Mills             "The requested resource blocks span multiple resource zones.",
66665e7602SGunnar Mills             "Critical",
67665e7602SGunnar Mills             0,
68665e7602SGunnar Mills             {},
69665e7602SGunnar Mills             "Request resource blocks from the same resource zone.",
70665e7602SGunnar Mills         }},
71665e7602SGunnar Mills     MessageEntry{
72665e7602SGunnar Mills         "NoResourceMatch",
73665e7602SGunnar Mills         {
74665e7602SGunnar Mills             "Indicates that the service could not find a matching resource based on the given parameters.",
75665e7602SGunnar Mills             "The requested resources of type '%1' are not available for allocation.",
76665e7602SGunnar Mills             "Critical",
77665e7602SGunnar Mills             1,
78665e7602SGunnar Mills             {
79665e7602SGunnar Mills                 "string",
80665e7602SGunnar Mills             },
81665e7602SGunnar Mills             "Change parameters associated with the resource, such as quantity or performance, and resubmit the request.",
82665e7602SGunnar Mills         }},
83665e7602SGunnar Mills     MessageEntry{
84665e7602SGunnar Mills         "ResourceBlockChanged",
85665e7602SGunnar Mills         {
86665e7602SGunnar Mills             "Indicates that a resource block has changed.  This is not used whenever there is another event message for that specific change, such as when only the state has changed.",
87665e7602SGunnar Mills             "Resource block '%1' has changed on the service.",
88665e7602SGunnar Mills             "OK",
89665e7602SGunnar Mills             1,
90665e7602SGunnar Mills             {
91665e7602SGunnar Mills                 "string",
92665e7602SGunnar Mills             },
93665e7602SGunnar Mills             "None.",
94665e7602SGunnar Mills         }},
95665e7602SGunnar Mills     MessageEntry{
96665e7602SGunnar Mills         "ResourceBlockCompositionStateChanged",
97665e7602SGunnar Mills         {
98665e7602SGunnar Mills             "Indicates that the composition state of a resource block has changed, specifically the value of the `CompositionState` property within `CompositionStatus`.",
99665e7602SGunnar Mills             "The composition status of the resource block '%1' has changed.",
100665e7602SGunnar Mills             "OK",
101665e7602SGunnar Mills             1,
102665e7602SGunnar Mills             {
103665e7602SGunnar Mills                 "string",
104665e7602SGunnar Mills             },
105665e7602SGunnar Mills             "None.",
106665e7602SGunnar Mills         }},
107665e7602SGunnar Mills     MessageEntry{
108665e7602SGunnar Mills         "ResourceBlockInUse",
109665e7602SGunnar Mills         {
110665e7602SGunnar Mills             "Indicates that the composition request contains a resource block that is unable to participate in more compositions.",
111665e7602SGunnar Mills             "Resource block '%1' cannot be part of any new compositions.",
112665e7602SGunnar Mills             "Warning",
113665e7602SGunnar Mills             1,
114665e7602SGunnar Mills             {
115665e7602SGunnar Mills                 "string",
116665e7602SGunnar Mills             },
117665e7602SGunnar Mills             "Remove the resource block from the request and resubmit the request.",
118665e7602SGunnar Mills         }},
119665e7602SGunnar Mills     MessageEntry{
120665e7602SGunnar Mills         "ResourceBlockInvalid",
121665e7602SGunnar Mills         {
122665e7602SGunnar Mills             "Indicates that the `Id` of a referenced resource block is no longer valid.",
123665e7602SGunnar Mills             "Resource block '%1' is not valid.",
124665e7602SGunnar Mills             "Critical",
125665e7602SGunnar Mills             1,
126665e7602SGunnar Mills             {
127665e7602SGunnar Mills                 "string",
128665e7602SGunnar Mills             },
129665e7602SGunnar Mills             "Remove the resource block and resubmit the request.",
130665e7602SGunnar Mills         }},
131665e7602SGunnar Mills     MessageEntry{
132665e7602SGunnar Mills         "ResourceBlockNotFound",
133665e7602SGunnar Mills         {
134665e7602SGunnar Mills             "Indicates that the referenced resource block was not found.",
135665e7602SGunnar Mills             "Resource block '%1' was not found.",
136665e7602SGunnar Mills             "Critical",
137665e7602SGunnar Mills             1,
138665e7602SGunnar Mills             {
139665e7602SGunnar Mills                 "string",
140665e7602SGunnar Mills             },
141665e7602SGunnar Mills             "Remove the resource block and resubmit the request.",
142665e7602SGunnar Mills         }},
143665e7602SGunnar Mills     MessageEntry{
144665e7602SGunnar Mills         "ResourceBlockStateChanged",
145665e7602SGunnar Mills         {
146665e7602SGunnar Mills             "Indicates that the state of a resource block has changed, specifically the value of the `State` property within `Status`.",
147665e7602SGunnar Mills             "The state of resource block '%1' has changed.",
148665e7602SGunnar Mills             "OK",
149665e7602SGunnar Mills             1,
150665e7602SGunnar Mills             {
151665e7602SGunnar Mills                 "string",
152665e7602SGunnar Mills             },
153665e7602SGunnar Mills             "None.",
154665e7602SGunnar Mills         }},
155665e7602SGunnar Mills     MessageEntry{
156665e7602SGunnar Mills         "ResourceZoneMembershipChanged",
157665e7602SGunnar Mills         {
158665e7602SGunnar Mills             "Indicates that the membership of a resource zone has changed due to resource blocks being added or removed from the resource zone.",
159665e7602SGunnar Mills             "The membership of resource zone '%1' has been changed.",
160665e7602SGunnar Mills             "OK",
161665e7602SGunnar Mills             1,
162665e7602SGunnar Mills             {
163665e7602SGunnar Mills                 "string",
164665e7602SGunnar Mills             },
165665e7602SGunnar Mills             "None.",
166665e7602SGunnar Mills         }},
167665e7602SGunnar Mills     MessageEntry{
168665e7602SGunnar Mills         "SpecifiedResourceAlreadyReserved",
169665e7602SGunnar Mills         {
170665e7602SGunnar Mills             "Indicates that a resource block is already reserved in response to a specific composition request.",
171665e7602SGunnar Mills             "Resource block '%1' is already reserved under reservation '%2'.",
172665e7602SGunnar Mills             "Critical",
173665e7602SGunnar Mills             2,
174665e7602SGunnar Mills             {
175665e7602SGunnar Mills                 "string",
176665e7602SGunnar Mills                 "string",
177665e7602SGunnar Mills             },
178665e7602SGunnar Mills             "Delete the reservation containing the resource block or select a different resource block and resubmit the request.",
179665e7602SGunnar Mills         }},
180665e7602SGunnar Mills     MessageEntry{
181665e7602SGunnar Mills         "UnableToProcessStanzaRequest",
182665e7602SGunnar Mills         {
183665e7602SGunnar Mills             "Indicates that the manifest provided for the `Compose` action contains a stanza with `Content` that could not be processed.",
184665e7602SGunnar Mills             "The provided manifest for the Compose action of type %1 contains a stanza with Id of value '%2' with a Content parameter that could not be processed.",
185665e7602SGunnar Mills             "Critical",
186665e7602SGunnar Mills             2,
187665e7602SGunnar Mills             {
188665e7602SGunnar Mills                 "string",
189665e7602SGunnar Mills                 "string",
190665e7602SGunnar Mills             },
191665e7602SGunnar Mills             "Add the Content parameter to the stanza or remove the stanza, and resubmit the request.",
192665e7602SGunnar Mills         }},
193665e7602SGunnar Mills 
194665e7602SGunnar Mills };
195665e7602SGunnar Mills 
196665e7602SGunnar Mills enum class Index
197665e7602SGunnar Mills {
198665e7602SGunnar Mills     constrainedResourceAlreadyReserved = 0,
199665e7602SGunnar Mills     emptyManifest = 1,
200665e7602SGunnar Mills     incompatibleZone = 2,
201665e7602SGunnar Mills     noResourceMatch = 3,
202665e7602SGunnar Mills     resourceBlockChanged = 4,
203665e7602SGunnar Mills     resourceBlockCompositionStateChanged = 5,
204665e7602SGunnar Mills     resourceBlockInUse = 6,
205665e7602SGunnar Mills     resourceBlockInvalid = 7,
206665e7602SGunnar Mills     resourceBlockNotFound = 8,
207665e7602SGunnar Mills     resourceBlockStateChanged = 9,
208665e7602SGunnar Mills     resourceZoneMembershipChanged = 10,
209665e7602SGunnar Mills     specifiedResourceAlreadyReserved = 11,
210665e7602SGunnar Mills     unableToProcessStanzaRequest = 12,
211665e7602SGunnar Mills };
212665e7602SGunnar Mills } // namespace redfish::registries::composition
213