Skip to content

Commit

Permalink
Add YANG model for alpm parity error (#12687)
Browse files Browse the repository at this point in the history
Add YANG model for alpm parity error
  • Loading branch information
zbud-msft authored Nov 14, 2022
1 parent 6d78199 commit 53779aa
Show file tree
Hide file tree
Showing 3 changed files with 78 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,20 @@
},
"SONIC_EVENTS_SYNCD_SYNCD_FAILURE_VALID": {
"desc": "VALID SYNCD_FAILURE EVENT."
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_INCORRECT_OPERATION": {
"desc": "ALPM_PARITY_ERROR_EVENT_INCORRECT_OPERATION failure.",
"eStrKey": "InvalidValue"
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_INCORRECT_IP_FAMILY": {
"desc": "ALPM_PARITY_ERROR_EVENT_INCORRECT_IP_FAMILY failure.",
"eStrKey": "InvalidValue"
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_INCORRECT_TIMESTAMP": {
"desc": "ALPM_PARITY_ERROR_EVENT_INCORRECT_TIMESTAMP failure.",
"eStrKey": "Pattern"
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_VALID": {
"desc": "VALID ALPM_PARITY_ERROR_EVENT."
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,41 @@
"timestamp": "1985-04-12T23:20:50.52Z"
}
}
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_INCORRECT_OPERATION": {
"sonic-events-syncd:sonic-events-syncd": {
"sonic-events-syncd:alpm-parity-error": {
"operation": "INVALID_OPERATION",
"ip_family": "IPv4",
"timestamp": "1985-04-12T23:20:50.52Z"
}
}
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_INCORRECT_IP_FAMILY": {
"sonic-events-syncd:sonic-events-syncd": {
"sonic-events-syncd:alpm-parity-error": {
"operation": "insert",
"ip_family": "INCORRECT_IP_FAMILY",
"timestamp": "1985-04-12T23:20:50.52Z"
}
}
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_INCORRECT_TIMESTAMP": {
"sonic-events-syncd:sonic-events-syncd": {
"sonic-events-syncd:alpm-parity-error": {
"operation": "delete",
"ip_family": "IPv6",
"timestamp": "INCORRECT_TIMESTAMP"
}
}
},
"SONIC_EVENTS_SYNCD_ALPM_PARITY_ERROR_VALID": {
"sonic-events-syncd:sonic-events-syncd": {
"sonic-events-syncd:alpm-parity-error": {
"operation": "insert",
"ip_family": "IPv4",
"timestamp": "1985-04-12T23:20:50.52Z"
}
}
}
}
27 changes: 27 additions & 0 deletions src/sonic-yang-models/yang-models/sonic-events-syncd.yang
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ module sonic-events-syncd {
revision-date 2022-12-01;
}

import sonic-types {
prefix stypes;
}

organization
"SONiC";

Expand Down Expand Up @@ -43,5 +47,28 @@ module sonic-events-syncd {

uses evtcmn:sonic-events-cmn;
}

container alpm-parity-error {
evtcmn:ALARM_SEVERITY_MAJOR;

description "
Declares an event for a parity error in ALPM
insert or delete for ipv4 or ipv6";

leaf operation {
type enumeration {
enum "insert";
enum "delete";
}
description "Operation for alpm parity error";
}

leaf ip_family {
type stypes:ip-family;
description "IP family for alpm parity error";
}

uses evtcmn:sonic-events-cmn;
}
}
}

0 comments on commit 53779aa

Please sign in to comment.