summaryrefslogtreecommitdiff
path: root/redfish-core/include/registries/network_device_message_registry.hpp
blob: c7c54ea812594f034bd1b56f931bdd2fcec45cfd (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
#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::network_device
{
const Header header = {
    "Copyright 2019-2023 DMTF. All rights reserved.",
    "#MessageRegistry.v1_6_2.MessageRegistry",
    "NetworkDevice.1.0.3",
    "Network Device Message Registry",
    "en",
    "This registry defines the messages for networking devices.",
    "NetworkDevice",
    "1.0.3",
    "DMTF",
};
constexpr const char* url =
    "https://redfish.dmtf.org/registries/NetworkDevice.1.0.3.json";

constexpr std::array registry =
{
    MessageEntry{
        "CableInserted",
        {
            "Indicates that a network cable was inserted.",
            "A network cable was inserted into network adapter '%1' port '%2'.",
            "OK",
            2,
            {
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "CableRemoved",
        {
            "Indicates that a network cable was removed.",
            "A cable was removed from network adapter '%1' port '%2'.",
            "OK",
            2,
            {
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ConnectionDropped",
        {
            "Indicates that a network connection was dropped.",
            "The connection is no longer active for network adapter '%1' port '%2' function '%3'.",
            "OK",
            3,
            {
                "string",
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ConnectionEstablished",
        {
            "Indicates that a network connection was established.",
            "A network connection was established for network adapter '%1' port '%2' function '%3'.",
            "OK",
            3,
            {
                "string",
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "DegradedConnectionEstablished",
        {
            "Indicates that a network connection was established, but at an unexpectedly low link speed.",
            "A degraded network connection was established for network adapter '%1' port '%2' function '%3'.",
            "Warning",
            3,
            {
                "string",
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "LinkFlapDetected",
        {
            "Indicates that a network connection is highly unstable.",
            "The network connection for network adapter '%1' port '%2' function '%3' was established and dropped '%4' times in the last '%5' minutes.",
            "Warning",
            5,
            {
                "string",
                "string",
                "string",
                "number",
                "number",
            },
            "Contact the network administrator for problem resolution.",
        }},

};

enum class Index
{
    cableInserted = 0,
    cableRemoved = 1,
    connectionDropped = 2,
    connectionEstablished = 3,
    degradedConnectionEstablished = 4,
    linkFlapDetected = 5,
};
} // namespace redfish::registries::network_device