Commit 54aa0567 authored by lengyelb's avatar lengyelb
Browse files

Added Scheduler and ConditionMonitor

parent e57ca17f
Loading
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -56,6 +56,7 @@ module _3gpp-common-measurements {
      Integration Reference Point (IRP);
      Information Service (IS)";

  revision 2024-05-06 { reference CR-xxxx; }
  revision 2024-02-24 { reference CR-0346; } 
  revision 2023-11-18 { reference "CR-0299 CR-0305"; }
  revision 2023-09-18 { reference CR-0271; } 
@@ -324,6 +325,17 @@ module _3gpp-common-measurements {
      description "Link to a 'Files' object.";
      yext3gpp:inVariant;
    }

    choice conditiona-or-schedule {
      leaf schedulerRef {
        type types3gpp:DistinguishedName;
        description "Pointer to a Scheduler object.";
      }
      leaf conditionMonitorRef {
        type types3gpp:DistinguishedName;
        description "Pointer to a ConditionMonitor object.";
      }
    }
  }


+218 −0
Original line number Diff line number Diff line
module _3gpp-common-util {
  yang-version 1.1;  
  namespace urn:3gpp:sa5:_3gpp-common-util;
  prefix "util3gpp";
  
  import _3gpp-common-top { prefix top3gpp; }  
  import _3gpp-common-yang-types { prefix types3gpp ; }
  import _3gpp-common-managed-element { prefix me3gpp ; }
  import _3gpp-common-subnetwork { prefix subnet3gpp ; }

  organization "3GPP SA5";
  contact "https://www.3gpp.org/DynaReport/TSG-WG--S5--officials.htm?Itemid=464";

  description "Defines Utility IOCs: ConditionMonitor, Scheduler
    Copyright 2024, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, 
    TTA, TTC). All rights reserved.";
  reference "3GPP TS 28.623";

  revision 2024-05-06 { reference CR-xxxx; }

  feature SchedulerUnderManagedElement {
    description "Scheduler shall be contained under ManagedElement.";
  }  

  feature SchedulerUnderSubNetwork {
    description "Scheduler shall be contained under SubNetwork.";
  }  
  
  grouping TimeIntervalGrp {
    description "This data type defines a time interval within one day. 
      If the whole day shall be selected, intervalStart shall be set to 
      00:00:00 and intervalEnd shall be set to 23:59:59.";
      
      leaf intervalStart {
        type types3gpp:FullTime;
        mandatory true;
        description "It indicates the time (in 'full-time' format) when the 
          service shall be started.
          Data type 'FullTime' defines the time as specified by 'full-time' 
          in RFC3339.";
      }
      
      leaf intervalEnd {
        type types3gpp:FullTime;
        mandatory true;
        description "It indicates the time (in 'full-time' format) when the 
          service shall be stopped.
          'FullTime' defines the time as specified by 'full-time' in RFC3339.
          intervalEnd should use the same timezone as intervalStart and shall 
          be later then intervalStart";
      }
  }
  
  grouping SchedulingTimeGrp {
    description "This <<choice>> defines the scheduling time and allows to 
      configure one of four possible scheduling methods: 

      - One time interval: The attribute timeWindow presents the active 
      scheduling time. A duration more than one day may be configured.
      - Daily periodicity: Several active intervals per day can be configured 
      in attribute timeIntervals. The active scheduling times recur each day.
      - Weekly periodicity: Several active intervals for one day can be 
      configured in attribute timeIntervals. The active scheduling times recur 
      on the days of the weeks configured by attribute daysOfWeek 
      - Monthly periodicity: Several active intervals for one day can be 
      configured in attribute timeIntervals. The active scheduling times 
      recur on the days of the months configured by attribute daysOfMonth.";
    choice SchedulingTime {
      mandatory true;
      case One-time-interval {
        uses types3gpp:TimeWindowGrp;
      }
      case periodic {
        list timeIntervals {
          description "List of intervals within one day for which the service 
            shall be active.";
            key "intervalStart intervalEnd";
            min-elements 1;
          uses TimeIntervalGrp;
        }
        leaf daysOfWeek {
          must 'not(../daysOfMonth)';
          description "Shall be present in case of Weekly periodicity, 
            otherwise not";
          type types3gpp:DayOfWeek;
        }
        leaf daysOfMonth {
          must 'not(../daysOfWeek)';
          description "Shall be present in case of Monthly periodicity, 
            otherwise not";
          type types3gpp:DaysOfMonth;
        }
      }
    }
  }
    
  grouping SchedulerGrp {
    description "Represents the Scheduler IOC.";
    
    list schedulingTimes {
      description "It defines the active scheduling times.";
      min-elements 1;
      key idx;
      leaf idx { type uint32; }
      uses SchedulingTimeGrp;
    }
    
    leaf schedulerStatus {
      type boolean;
      mandatory true;
      config false;
      description "Switches between TRUE and FALSE depending upon whether the 
        configured time constraints are fulfilled or not.";
    }
  }
  
  grouping SchedulerSubtree {
    list Scheduler {
      description "This IOC defines a time scheduler. 
        It can be name-contained by SubNetwork or ManagedElement.
        
        The attribute schedulingTimes allows to configure one or several 
        active time intervals. The active intervals can be configured to occur 
        once or recurring periodically.
        
        The boolean attribute schedulerStatus switches between TRUE and FALSE 
        depending upon whether the configured time constraints are fulfilled 
        or not. This attribute makes the internal Scheduler status observable.";
      key id;   
      uses top3gpp:Top_Grp;
      container attributes {
        uses SchedulerGrp;
      }      
    }
  }
  
  augment /me3gpp:ManagedElement {
    if-feature SchedulerUnderManagedElement;
    uses SchedulerSubtree;
  }
  augment /subnet3gpp:SubNetwork {
    if-feature SchedulerUnderSubNetwork;
    uses SchedulerSubtree;
  }
  
///////////////////////////////////////////////////////////////////////////////

  feature ConditionMonitorUnderManagedElement {
    description "ConditionMonitor shall be contained under ManagedElement.";
  }  

  feature ConditionMonitorUnderSubNetwork {
    description "ConditionMonitor shall be contained under SubNetwork.";
  }  

  grouping ConditionMonitorGrp {
    description "Represents the Scheduler IOC.";
    
    leaf condition {
      type string {
        length 1..max;
      }
      mandatory true;
      description "Logical expression of one or several condition(s). 

        The actual syntax and capabilities of condition is SS specific. 
        However, each SS should support condition consisting of one or several 
        assertions that may be grouped using the logical operators AND, OR 
        and NOT. Only if the whole expression of condition evaluates TRUE, 
        the attribute conditionsSatisfied will be TRUE.

        Each assertion is a pointer to a Boolean parameter or a logical 
        expression of attribute existence or attribute value comparison 
        ('equal to X, less than Y' etc.).

        An empty string is not allowed.";
    }
    
    leaf conditionStatus {
      type boolean;
      mandatory true;
      config false;
      description "Switches between TRUE and FALSE depending upon whether the 
        configured constraints are fulfilled or not.";
    }
  }
  
  grouping ConditionMonitorSubtree {
    list ConditionMonitor {
      description "This IOC defines one or several conditions and monitors 
        whether these conditions are satisfied. It can be name-contained by 
        SubNetwork or ManagedElement.
        
        The attribute condition allows to configure one or several conditions. 
        Possible conditions include but are not limited to scheduling 
        requirements or parameter settings e.g. evaluation if a configuration 
        parameter is above a certain threshold or has a certain values. 
        
        The boolean attribute conditionStatus switches between TRUE and FALSE 
        depending upon whether the configured conditions are fulfilled or not. 
        This attribute makes the internal ConditionMonitor status observable.";
      key id;   
      uses top3gpp:Top_Grp;
      container attributes {
        uses ConditionMonitorGrp;
      }      
    }
  }
  
  augment /me3gpp:ManagedElement {
    if-feature ConditionMonitorUnderManagedElement;
    uses ConditionMonitorSubtree;
  }
  augment /subnet3gpp:SubNetwork {
    if-feature ConditionMonitorUnderSubNetwork;
    uses ConditionMonitorSubtree;
  }  
}
 No newline at end of file
+34 −0
Original line number Diff line number Diff line
@@ -69,6 +69,40 @@ module _3gpp-common-yang-types {
    leaf value { type string; }
  }

  typedef DayOfWeekT {
    type enumeration {
      enum Monday;
      enum Tuesday;
      enum Wednesday;
      enum Thursday;
      enum Friday;
      enum Saturday;
      enum Sunday;
    }
  }
  
  typedef DayOfWeek {
    type enumeration {
      enum MONDAY;
      enum TUESDAY;
      enum WEDNESDAY;
      enum THURSADY;
      enum FRIDAY;
      enum SATURDAY;
      enum SUNDAY;
    }
  }
  
  typedef DaysOfMonth {
    type uint8 {
      range 0..31;
    }
  }
  
  typedef FullTime {
    type yang:time-with-zone-offset;
  }

  grouping TimeWindowGrp {
    leaf startTime {
      type yang:date-and-time;
+457 −289

File changed.

Preview size limit exceeded, changes collapsed.

+348 −89

File changed and moved.File mode changed from 100755 to 100644.

Preview size limit exceeded, changes collapsed.