blob: a88692468b22b7606435e13bf46d5f5be97b359b [file] [log] [blame]
Chip Boling6e27b352020-02-14 09:10:01 -06001/*
2 * Copyright (c) 2018 - present. Boling Consulting Solutions (bcsw.net)
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 * http://www.apache.org/licenses/LICENSE-2.0
8 * Unless required by applicable law or agreed to in writing, software
9 * distributed under the License is distributed on an "AS IS" BASIS,
10 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 * See the License for the specific language governing permissions and
12 * limitations under the License.
13 */
14/*
15 * NOTE: This file was generated, manual edits will be overwritten!
16 *
17 * Generated by 'goCodeGenerator.py':
18 * https://github.com/cboling/OMCI-parser/README.md
19 */
20
21package generated
22
23import "github.com/deckarep/golang-set"
24
25// PseudowirePerformanceMonitoringHistoryDataClassID is the 16-bit ID for the OMCI
26// Managed entity Pseudowire performance monitoring history data
27const PseudowirePerformanceMonitoringHistoryDataClassID ClassID = ClassID(285)
28
29var pseudowireperformancemonitoringhistorydataBME *ManagedEntityDefinition
30
31// PseudowirePerformanceMonitoringHistoryData (class ID #285)
32// This ME collects PM for a pseudowire TP. Most of the attributes monitor packets received from
33// the PSN, and may therefore be considered egress PM. For the most part, ingress PM is collected
34// at the CES PPTP ME.
35//
36// NOTE - The pseudowire PM history data ME collects data similar, but not identical, to that
37// available from the MAC bridge port PM history data ME associated with a MAC bridge. When the
38// pseudowire is bridge-based, it may not be necessary to collect both.
39//
40// Instances of this ME are created and deleted by the OLT.
41//
42// For a complete discussion of generic PM architecture, refer to clause I.4.
43//
44// Relationships
45// An instance of this ME is associated with an instance of the pseudowire TP.
46//
47// Attributes
48// Managed Entity Id
49// Managed entity ID: This attribute uniquely identifies each instance of this ME. Through an
50// identical ID, this ME is implicitly linked to an instance of the pseudowire TP. (R, setbycreate)
51// (mandatory) (2-bytes)
52//
53// Interval End Time
54// Interval end time: This attribute identifies the most recently finished 15-min interval. (R)
55// (mandatory) (1-byte)
56//
57// Threshold Data 1_2 Id
58// Threshold data 1/2 ID: This attribute points to an instance of the threshold data 1 and 2 MEs
59// that contains PM threshold values. (R,-W, setbycreate) (mandatory) (2-bytes)
60//
61// Received Packets
62// Received packets: This attribute counts the total number of packets, both payload and
63// signalling, received in the PSN to the TDM direction. (R) (mandatory) (4-bytes)
64//
65// Transmitted Packets
66// Transmitted packets: This attribute counts the total number of packets, both payload and
67// signalling, transmitted in the TDM to the PSN direction. The count includes packets whose L bit
68// is set and which may therefore not contain a payload. (R) (mandatory) (4-bytes)
69//
70// Missing Packets
71// Missing packets: This attribute counts the number of lost packets, as indicated by gaps in the
72// control word numbering sequence. Both payload and signalling packets, if any, contribute to this
73// count. (R) (mandatory) (4-bytes)
74//
75// Misordered Packets, Usable
76// Misordered packets, usable: This attribute counts the number of packets received out of order,
77// but which were able to be successfully re-ordered and played out. Both payload and signalling
78// packets, if any, contribute to this count. (R) (mandatory) (4-bytes)
79//
80// Misordered Packets Dropped
81// Misordered packets dropped: This attribute counts the number of packets received out of sequence
82// that were discarded, either because the ONU did not support reordering or because it was too
83// late to reorder them. Both payload and signalling packets, if any, contribute to this count. (R)
84// (mandatory) (4-bytes)
85//
86// Playout Buffer Underruns_Overruns
87// Playout buffer underruns/overruns: This attribute counts the number of packets that were
88// discarded because they arrived too late or too early to be played out. Both payload and
89// signalling packets, if any, contribute to this count. (R) (mandatory) (4-bytes)
90//
91// Malformed Packets
92// Malformed packets: This attribute counts the number of malformed packets, e.g., because the
93// packet length was not as expected or because of an unexpected RTP payload type. Both payload and
94// signalling packets, if any, contribute to this count. (R) (mandatory) (4-bytes)
95//
96// Stray Packets
97// Stray packets: This attribute counts the number of packets whose ECID or RTP SSRC failed to
98// match the expected value, or which are otherwise known to have been misdelivered. Stray packets
99// are discarded without affecting any of the other PM counters. Both payload and signalling
100// packets, if any, contribute to this count. (R) (mandatory) (4-bytes)
101//
102// Remote Packet Loss
103// Remote packet loss: This attribute counts received packets whose R bit is set, indicating the
104// loss of packets at the far end. Both payload and signalling packets, if any, contribute to this
105// count. (R) (mandatory) (4-bytes)
106//
107// Tdm L_Bit Packets Transmitted
108// TDM L-bit packets transmitted: This attribute counts the number of packets transmitted with the
109// L bit set, indicating a near-end TDM fault. Both payload and signalling packets, if any,
110// contribute to this count. (R) (mandatory) (4-bytes)
111//
112// Es
113// ES: This attribute counts errored seconds. Any discarded, lost, malformed or unusable packet
114// received from the PSN during a given second causes this counter to increment. Both payload and
115// signalling packets, if any, contribute to this count. (R) (mandatory) (4-bytes)
116//
117// Ses
118// SES: This attribute counts severely errored seconds. The criterion for an SES may be configured
119// through the pseudowire maintenance profile ME. Both payload and signalling packets, if any,
120// contribute to this count. (R) (mandatory) (4-bytes)
121//
122// Uas
123// UAS: This attribute counts unavailable seconds. An unavailable second begins at the onset of 10
124// consecutive SES and ends at the onset of 10 consecutive seconds that are not severely errored. A
125// service is unavailable if either its payload or its signalling, if any, are unavailable. During
126// unavailable time, only UAS should be counted; other anomalies should not be counted. (R)
127// (mandatory) (4-bytes)
128//
129type PseudowirePerformanceMonitoringHistoryData struct {
130 ManagedEntityDefinition
131 Attributes AttributeValueMap
132}
133
134func init() {
135 pseudowireperformancemonitoringhistorydataBME = &ManagedEntityDefinition{
136 Name: "PseudowirePerformanceMonitoringHistoryData",
137 ClassID: 285,
138 MessageTypes: mapset.NewSetWith(
139 Create,
140 Delete,
141 Get,
142 Set,
143 ),
144 AllowedAttributeMask: 0xfffe,
145 AttributeDefinitions: AttributeDefinitionMap{
146 0: Uint16Field("ManagedEntityId", PointerAttributeType, 0x0000, 0, mapset.NewSetWith(Read, SetByCreate), false, false, false, 0),
147 1: ByteField("IntervalEndTime", UnsignedIntegerAttributeType, 0x8000, 0, mapset.NewSetWith(Read), false, false, false, 1),
148 2: Uint16Field("ThresholdData12Id", UnsignedIntegerAttributeType, 0x4000, 0, mapset.NewSetWith(Read, SetByCreate, Write), false, false, false, 2),
149 3: Uint32Field("ReceivedPackets", CounterAttributeType, 0x2000, 0, mapset.NewSetWith(Read), false, false, false, 3),
150 4: Uint32Field("TransmittedPackets", CounterAttributeType, 0x1000, 0, mapset.NewSetWith(Read), false, false, false, 4),
151 5: Uint32Field("MissingPackets", CounterAttributeType, 0x0800, 0, mapset.NewSetWith(Read), false, false, false, 5),
152 6: Uint32Field("MisorderedPackets,Usable", CounterAttributeType, 0x0400, 0, mapset.NewSetWith(Read), false, false, false, 6),
153 7: Uint32Field("MisorderedPacketsDropped", CounterAttributeType, 0x0200, 0, mapset.NewSetWith(Read), false, false, false, 7),
154 8: Uint32Field("PlayoutBufferUnderrunsOverruns", CounterAttributeType, 0x0100, 0, mapset.NewSetWith(Read), false, false, false, 8),
155 9: Uint32Field("MalformedPackets", CounterAttributeType, 0x0080, 0, mapset.NewSetWith(Read), false, false, false, 9),
156 10: Uint32Field("StrayPackets", CounterAttributeType, 0x0040, 0, mapset.NewSetWith(Read), false, false, false, 10),
157 11: Uint32Field("RemotePacketLoss", CounterAttributeType, 0x0020, 0, mapset.NewSetWith(Read), false, false, false, 11),
158 12: Uint32Field("TdmLBitPacketsTransmitted", CounterAttributeType, 0x0010, 0, mapset.NewSetWith(Read), false, false, false, 12),
159 13: Uint32Field("Es", CounterAttributeType, 0x0008, 0, mapset.NewSetWith(Read), false, false, false, 13),
160 14: Uint32Field("Ses", CounterAttributeType, 0x0004, 0, mapset.NewSetWith(Read), false, false, false, 14),
161 15: Uint32Field("Uas", CounterAttributeType, 0x0002, 0, mapset.NewSetWith(Read), false, false, false, 15),
162 },
163 Access: CreatedByOlt,
164 Support: UnknownSupport,
165 }
166}
167
168// NewPseudowirePerformanceMonitoringHistoryData (class ID 285) creates the basic
169// Managed Entity definition that is used to validate an ME of this type that
170// is received from or transmitted to the OMCC.
171func NewPseudowirePerformanceMonitoringHistoryData(params ...ParamData) (*ManagedEntity, OmciErrors) {
172 return NewManagedEntity(*pseudowireperformancemonitoringhistorydataBME, params...)
173}