Skip to content

Commit

Permalink
Update openconfig-gnsi-acctz.yang
Browse files Browse the repository at this point in the history
* Delete idle-timeouts and counters-last-cleared leaves
* Split source-counters and client counters to be under separate augments
  • Loading branch information
adityasingh-anet committed Oct 10, 2024
1 parent 3a30185 commit 0c3094f
Showing 1 changed file with 58 additions and 52 deletions.
110 changes: 58 additions & 52 deletions release/models/gnsi/openconfig-gnsi-acctz.yang
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,6 @@ module openconfig-gnsi-acctz {
import openconfig-system-grpc {
prefix oc-sys-grpc;
}
import openconfig-types {
prefix oc-types;
}
import openconfig-yang-types {
prefix oc-yang;
}
Expand All @@ -30,7 +27,14 @@ module openconfig-gnsi-acctz {
"This module provides counters of gNSI accountZ requests and responses and
the quantity of data transferred.";

oc-ext:openconfig-version "0.2.0";
oc-ext:openconfig-version "0.3.0";

revision 2024-10-07 {
description
"Remove `idle-timeouts` and `counters-last-cleared` leaves.
Relocate source-counters and client-counters to separate paths";
reference "0.3.0";
}

revision 2024-02-13 {
description
Expand Down Expand Up @@ -116,34 +120,33 @@ module openconfig-gnsi-acctz {
description
"A collection of counters that were collected by the gNSI.acctz
module while servicing acctz clients.";

container client-counters {
description
"A collection of counters that were collected by the gNSI.acctz
module while servicing acctz clients.";
leaf history-istruncated {
type oc-yang:counter64;
description
"The total number of times that a RecordRequest resulted in
a RecordResponse being marked history-istruncated. ie: a
request was made for a timestamp that did not exist in the
history.";
}
leaf idle-timeouts {
type oc-yang:counter64;
description
"The total number of times that a client was disconnected
due to missing keepalives (ie: RecordRequests).";
}
leaf record-requests {
type oc-yang:counter64;
container state {
description
"The total number of RecordRequest RPCs that have been received.";
}
leaf record-responses {
type oc-yang:counter64;
"Operational state relating to acctz-counters.";

container counters {
description
"The total number of RecordResponse RPCs that have been sent.";
"A collection of counters that were collected by the gNSI.acctz
module while servicing acctz clients.";

leaf history-istruncated {
type oc-yang:counter64;
description
"The total number of times that a RecordRequest resulted in
a RecordResponse being marked history-istruncated. ie: a
request was made for a timestamp that did not exist in the
history.";
}
leaf record-requests {
type oc-yang:counter64;
description
"The total number of RecordRequest messages that have been received.";
}
leaf record-responses {
type oc-yang:counter64;
description
"The total number of RecordResponse messages that have been sent.";
}
}
}
}
Expand All @@ -154,16 +157,15 @@ module openconfig-gnsi-acctz {
"A collection of counters for gNSI.acctz record production per
service request type.";

container source-counters {
container counters {
description
"A collection of counters for gNSI.acctz record production per
service request type.";
list source-records {
key "service type";
// unique "service type";
description
"The total number of times the gNSI.authz module denied access
to a RPC.";
"A collection of the number of records produced for each service-request type.";

leaf service {
type leafref {
Expand Down Expand Up @@ -207,29 +209,26 @@ module openconfig-gnsi-acctz {

grouping grpc-server-acctz-counters {
description
"A collection of counters from the gNSI.acctz module.";
"A collection of counters from the gNSI.acctz module. This collection
augments the existing certz grpc counters";

container acctz-counters {
container acctz {
config false;
description
"A collection of counters from the gNSI.acctz module
for acctz clients and sources.";

container state {
description
"Operational state relating to acctz-counters.";

leaf counters-last-cleared {
type oc-types:timeticks64;
description
"The last time that the counters were cleared (reset to
zero). This value is reported as nanoseconds since epoch
(January 1st, 1970 00:00:00 GMT).";
}
"A collection of counters from the gNSI.acctz module. This collection
augments the existing certz grpc counters";
uses client-counters;
}
}

uses client-counters;
}
grouping system-acctz-counters {
description
"A collection of counters from the gNSI.acctz module.";

container acctz {
config false;
description
"A collection of counters from the gNSI.acctz module.";
uses source-counters;
}
}
Expand All @@ -238,8 +237,15 @@ module openconfig-gnsi-acctz {
augment "/oc-sys:system/oc-sys-grpc:grpc-servers/oc-sys-grpc:grpc-server" {
when "config[contains(services, 'oc-gnsi:GNSI')]/enable = 'true'";
description
"Counters collected by the gNSI.acctz module.";
"Counters collected by the gNSI.acctz module regarding grpc servers.";

uses grpc-server-acctz-counters;
}

augment "/oc-sys:system/oc-sys:aaa/oc-sys:accounting" {
description
"Counters collected by the gNSI.acctz module regarding the system.";

uses system-acctz-counters;
}
}

0 comments on commit 0c3094f

Please sign in to comment.