Skip to content

Commit

Permalink
Add config and state for individual Ethernet port priority in a LAG (o…
Browse files Browse the repository at this point in the history
…penconfig#943)

* add config container to LACP aggregate interface member

Add config container for LACP aggregate interface member with port-priority
and interface. Change /lacp/interfaces/interface/members/member/interface to
point to the new leaf /lacp/interfaces/interface/members/member/config/interface.
Change /lacp/interfaces/interface/members to config true.

This change is not backwards compatible due to breaking change of changing type for list

---------

Co-authored-by: Darren Loher <[email protected]>
Co-authored-by: Rob Shakir <[email protected]>
  • Loading branch information
3 people authored Dec 12, 2023
1 parent 4e15058 commit 48a1c13
Showing 1 changed file with 37 additions and 17 deletions.
54 changes: 37 additions & 17 deletions release/models/lacp/openconfig-lacp.yang
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,14 @@ module openconfig-lacp {
managing aggregate interfaces. It works in conjunction with
the OpenConfig interfaces and aggregate interfaces models.";

oc-ext:openconfig-version "1.2.0";
oc-ext:openconfig-version "2.0.0";

revision "2023-12-11" {
description
"Add config container for aggregation member and port-priority leaf under
both config and state";
reference "2.0.0";
}

revision "2021-07-20" {
description
Expand Down Expand Up @@ -138,20 +145,23 @@ module openconfig-lacp {
description
"Configuration data for lacp member interfaces";

//currently a placeholder -- the list of member interfaces
//and their status is considered opstate only
}

grouping aggregation-lacp-members-state {
description
"Operational status data for the member interfaces";

leaf interface {
type oc-if:base-interface-ref;
description
"Reference to interface member of the LACP aggregate";
}

leaf port-priority {
type uint16;
description
"Member interface's priority in its aggregate interface.";
}
}

grouping aggregation-lacp-members-state {
description
"Operational status data for the member interfaces";

leaf activity {
type lacp-activity-type;
description "Indicates participant is active or passive";
Expand Down Expand Up @@ -234,6 +244,12 @@ module openconfig-lacp {
port";
}

leaf partner-port-priority {
type uint16;
description
"Member interface partner's priority in its aggregate interface.";
}

leaf last-change {
type oc-types:timeticks64;
description
Expand Down Expand Up @@ -310,28 +326,31 @@ grouping aggregation-lacp-members-statistics {
"Top-level grouping for aggregate members list";

container members {
config false;
description
"Enclosing container for the list of members interfaces of
the aggregate. This list is considered operational state
only so is labeled config false and has no config container";
"Configuration and operational state of the aggregate member
interfaces";

list member {
key "interface";
description
"List of member interfaces and their associated status for
a LACP-controlled aggregate interface. Member list is not
configurable here -- each interface indicates items
its participation in the LAG.";
a LACP-controlled aggregate interface";

leaf interface {
type leafref {
path "../state/interface";
path "../config/interface";
}
description
"Reference to aggregate member interface";
}

container config {
description
"Operational state data for aggregate members";

uses aggregation-lacp-members-config;
}


container state {

Expand All @@ -340,6 +359,7 @@ grouping aggregation-lacp-members-statistics {
description
"Operational state data for aggregate members";

uses aggregation-lacp-members-config;
uses aggregation-lacp-members-state;
uses aggregation-lacp-members-statistics;
}
Expand Down

0 comments on commit 48a1c13

Please sign in to comment.