summaryrefslogtreecommitdiff
path: root/redfish-core/include/registries/composition_message_registry.hpp
blob: a566083b373b87049c08d05c42e7a5c016fdda40 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
#pragma once
/****************************************************************
 *                 READ THIS WARNING FIRST
 * This is an auto-generated header which contains definitions
 * for Redfish DMTF defined messages.
 * DO NOT modify this registry outside of running the
 * parse_registries.py script.  The definitions contained within
 * this file are owned by DMTF.  Any modifications to these files
 * should be first pushed to the relevant registry in the DMTF
 * github organization.
 ***************************************************************/
#include "registries.hpp"

#include <array>

// clang-format off

namespace redfish::registries::composition
{
const Header header = {
    "Copyright 2019-2023 DMTF. All rights reserved.",
    "#MessageRegistry.v1_6_2.MessageRegistry",
    "Composition.1.1.2",
    "Composition Message Registry",
    "en",
    "This registry defines the messages for composition related events.",
    "Composition",
    "1.1.2",
    "DMTF",
};
constexpr const char* url =
    "https://redfish.dmtf.org/registries/Composition.1.1.2.json";

constexpr std::array registry =
{
    MessageEntry{
        "ConstrainedResourceAlreadyReserved",
        {
            "Indicates that the requested resources are already reserved in response to a constrained composition request.",
            "The requested resources are reserved under reservation '%1'.",
            "Critical",
            1,
            {
                "string",
            },
            "Delete the reservation containing the resources and resubmit the request.",
        }},
    MessageEntry{
        "EmptyManifest",
        {
            "Indicates that the manifest contains no stanzas or that a stanza in the manifest contains no request.",
            "The provided manifest is empty or a stanza in the manifest contains no request.",
            "Warning",
            0,
            {},
            "Provide a request content for the manifest and resubmit.",
        }},
    MessageEntry{
        "IncompatibleZone",
        {
            "Indicates that not all referenced resource blocks are in the same resource zone.",
            "The requested resource blocks span multiple resource zones.",
            "Critical",
            0,
            {},
            "Request resource blocks from the same resource zone.",
        }},
    MessageEntry{
        "NoResourceMatch",
        {
            "Indicates that the service could not find a matching resource based on the given parameters.",
            "The requested resources of type '%1' are not available for allocation.",
            "Critical",
            1,
            {
                "string",
            },
            "Change parameters associated with the resource, such as quantity or performance, and resubmit the request.",
        }},
    MessageEntry{
        "ResourceBlockChanged",
        {
            "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.",
            "Resource block '%1' has changed on the service.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ResourceBlockCompositionStateChanged",
        {
            "Indicates that the composition state of a resource block has changed, specifically the value of the `CompositionState` property within `CompositionStatus`.",
            "The composition status of the resource block '%1' has changed.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ResourceBlockInUse",
        {
            "Indicates that the composition request contains a resource block that is unable to participate in more compositions.",
            "Resource block '%1' cannot be part of any new compositions.",
            "Warning",
            1,
            {
                "string",
            },
            "Remove the resource block from the request and resubmit the request.",
        }},
    MessageEntry{
        "ResourceBlockInvalid",
        {
            "Indicates that the `Id` of a referenced resource block is no longer valid.",
            "Resource block '%1' is not valid.",
            "Critical",
            1,
            {
                "string",
            },
            "Remove the resource block and resubmit the request.",
        }},
    MessageEntry{
        "ResourceBlockNotFound",
        {
            "Indicates that the referenced resource block was not found.",
            "Resource block '%1' was not found.",
            "Critical",
            1,
            {
                "string",
            },
            "Remove the resource block and resubmit the request.",
        }},
    MessageEntry{
        "ResourceBlockStateChanged",
        {
            "Indicates that the state of a resource block has changed, specifically the value of the `State` property within `Status`.",
            "The state of resource block '%1' has changed.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ResourceZoneMembershipChanged",
        {
            "Indicates that the membership of a resource zone has changed due to resource blocks being added or removed from the resource zone.",
            "The membership of resource zone '%1' has been changed.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "SpecifiedResourceAlreadyReserved",
        {
            "Indicates that a resource block is already reserved in response to a specific composition request.",
            "Resource block '%1' is already reserved under reservation '%2'.",
            "Critical",
            2,
            {
                "string",
                "string",
            },
            "Delete the reservation containing the resource block or select a different resource block and resubmit the request.",
        }},
    MessageEntry{
        "UnableToProcessStanzaRequest",
        {
            "Indicates that the manifest provided for the `Compose` action contains a stanza with `Content` that could not be processed.",
            "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.",
            "Critical",
            2,
            {
                "string",
                "string",
            },
            "Add the Content parameter to the stanza or remove the stanza, and resubmit the request.",
        }},

};

enum class Index
{
    constrainedResourceAlreadyReserved = 0,
    emptyManifest = 1,
    incompatibleZone = 2,
    noResourceMatch = 3,
    resourceBlockChanged = 4,
    resourceBlockCompositionStateChanged = 5,
    resourceBlockInUse = 6,
    resourceBlockInvalid = 7,
    resourceBlockNotFound = 8,
    resourceBlockStateChanged = 9,
    resourceZoneMembershipChanged = 10,
    specifiedResourceAlreadyReserved = 11,
    unableToProcessStanzaRequest = 12,
};
} // namespace redfish::registries::composition