yp-controller operation manager Copyright (c) 2018 YumaWorks, Inc. All rights reserved. Redistribution and use in source and b...
Version: 2018-07-10
module yumaworks-opsmgr { yang-version 1.1; namespace "http://yumaworks.com/ns/yumaworks-opsmgr"; prefix yomgr; import ietf-yang-types { prefix yang; } import yuma-types { prefix nt; } import yumaworks-mgr-common { prefix ymcmn; } organization "YumaWorks, Inc."; contact "Support <support at yumaworks.com>"; description "yp-controller operation manager Copyright (c) 2018 YumaWorks, Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, is permitted pursuant to, and subject to the license terms contained in, the BSD 3-Clause License http://opensource.org/licenses/BSD-3-Clause. "; revision "2018-07-10" { description "Initial version"; } rpc get-capabilities { description "Retrieve the NETCONF or RESTCONF capabilities for the specified sessions. The session-name leaf-list is considered to be a logical OR expression. A 'session-output' list entry will be returned for each matching session name that corresponds to a session for which the capabilities are available."; input { leaf-list session-name { type union { type string { pattern '\*'; } type nt:NcxName; } min-elements 1; description "The name of a session or callhome-session entry."; } } output { choice output-choice { leaf async-mode-started { type empty; description "Indicates the async mode was used and the operation was started successfully on at least one session."; } list session-output { key "session-name"; description "One entry represents the output from one session. If the operation was not attempted because the input parameter values (e.g., stop-time before start-time) then no entries will exist in this list and the operation will return an empty rpc-reply element instead."; leaf session-name { type nt:NcxName; description "The name of the session that the RPC operation was attempted. This name identifies an entry in the /sesmgr/sessions/session list or the /sesmgr/sessions/callhome-session list."; } choice cmd-result { leaf timeout-error { type empty; description "The operation reply was not received before the timeout."; } leaf other-error { type string; description "The error string for some other error that occurred sending the request. This case is not used if a valid response was received,"; } container data { description "The output data from the operation. The RPC operation using this grouping will augment this container with the data that is expected for that message. There will be one or more child nodes present, depending on the operation."; container capabilities { leaf-list capability { type string; description "The NETCONF or RESTCONF URI string for the capability"; } } // container capabilities } // container data } // choice cmd-result } // list session-output } // choice output-choice } } // rpc get-capabilities rpc get-event-log { description "Retrieve raw events from the event log for 1 or more sessions. The input filters are combined to form a logical AND expression. All filters that are present must pass for an event to be included in the response. The session-name leaf-list is considered to be a logical OR expression. A 'session-output' list entry will be returned for each matching session name that corresponds to the event log that search results were found. All invalid values are considered to be false matches and not errors."; input { leaf-list session-name { type union { type string { pattern '\*'; } type nt:NcxName; } min-elements 1; description "The name of a session or callhome-session entry."; } leaf start-index { type uint32; default '1'; description "The start index number in the event log to use. The first event is event 1."; } leaf max-entries { type uint32; default '0'; description "The maximum number of entries to return. The value zero indicates there is no maximum."; } leaf start-time { type yang:date-and-time; description "The timestamp to compare to the subscription eventTime value. Events timestamped at or after this value will be included in the response."; } leaf finish-time { type yang:date-and-time; description "The timestamp to compare to the subscription eventTime value. Events timestamped at or before this value will be included in the response."; } leaf module-name { type nt:NcxName; description "The name of the module that contains the notification statement associated with the event type. Events matching this module name will be included in the response."; } leaf event-name { type nt:NcxName; description "The local name of the notification statement associated with the event type. Events matching this notification name will be included n the response."; } leaf xpath-filter { type yang:xpath1.0; description "An XPath expression to test against the notification. The document root and the context node will be the notification element. The result will be converted using the boolean() function if required. If the boolean result is 'true' then the event will be included in the response;"; } } output { choice output-choice { leaf async-mode-started { type empty; description "Indicates the async mode was used and the operation was started successfully on at least one session."; } list session-output { key "session-name"; description "One entry represents the output from one session. If the operation was not attempted because the input parameter values (e.g., stop-time before start-time) then no entries will exist in this list and the operation will return an empty rpc-reply element instead."; leaf session-name { type nt:NcxName; description "The name of the session that the RPC operation was attempted. This name identifies an entry in the /sesmgr/sessions/session list or the /sesmgr/sessions/callhome-session list."; } choice cmd-result { leaf timeout-error { type empty; description "The operation reply was not received before the timeout."; } leaf other-error { type string; description "The error string for some other error that occurred sending the request. This case is not used if a valid response was received,"; } container data { description "The output data from the operation. The RPC operation using this grouping will augment this container with the data that is expected for that message. There will be one or more child nodes present, depending on the operation."; list event-data { key "index"; leaf index { type uint32; description "The event index in the eventlog of this event."; } anydata notification { description "The complete notification message"; } } // list event-data } // container data } // choice cmd-result } // list session-output } // choice output-choice } } // rpc get-event-log rpc invoke-rpc { description "Invoke an RPC operation for 1 or more sessions. The session-name leaf-list is considered to be a logical OR expression. A 'session-output' list entry will be returned for each matching session name that corresponds to a session for which the RPC operation was attempted. "; input { leaf-list session-name { type union { type string { pattern '\*'; } type nt:NcxName; } min-elements 1; description "The name of a session or callhome-session entry."; } leaf module-name { type nt:NcxName; mandatory true; description "The name of the module that contains the RPC statement that should be invoked."; } leaf rpc-name { type nt:NcxName; mandatory true; description "The local name of the RPC operation statement that should be invoked."; } leaf message-id { type string; description "If present, send the request in async mode. The message-id string to use in the cmd-response event sent for this command. The cmd-response event is sent when there is a real response ready. The rpc-reply for this operation indicates that the command was started."; } leaf timeout { type int32 { range "0..max"; } units "seconds"; default "30"; description "The number of seconds to wait for a reply from each session. The value zero indicates wait forever."; } anydata input { description "The input parameters for this RPC operation. The child nodes of this node are expected to be the child nodes of the 'input' statement for the associated RPC operation."; } } output { choice output-choice { leaf async-mode-started { type empty; description "Indicates the async mode was used and the operation was started successfully on at least one session."; } list session-output { key "session-name"; description "One entry represents the output from one session. If the operation was not attempted because the input parameter values (e.g., stop-time before start-time) then no entries will exist in this list and the operation will return an empty rpc-reply element instead."; leaf session-name { type nt:NcxName; description "The name of the session that the RPC operation was attempted. This name identifies an entry in the /sesmgr/sessions/session list or the /sesmgr/sessions/callhome-session list."; } choice cmd-result { leaf timeout-error { type empty; description "The operation reply was not received before the timeout."; } leaf other-error { type string; description "The error string for some other error that occurred sending the request. This case is not used if a valid response was received,"; } container data { description "The output data from the operation. The RPC operation using this grouping will augment this container with the data that is expected for that message. There will be one or more child nodes present, depending on the operation."; } // container data } // choice cmd-result } // list session-output } // choice output-choice } } // rpc invoke-rpc rpc invoke-action { description "Invoke a YANG action for 1 or more sessions. The session-name leaf-list is considered to be a logical OR expression. A 'session-output' list entry will be returned for each matching session name that corresponds to a session for which the action was attempted. "; input { leaf-list session-name { type union { type string { pattern '\*'; } type nt:NcxName; } min-elements 1; description "The name of a session or callhome-session entry."; } leaf action-path { type string; mandatory true; description "The RESTCONF URL for the action object. All ancestor key values must be provided so that the target node represents one conceptual instance of the YANG action node."; } leaf message-id { type string; description "If present, send the request in async mode. The message-id string to use in the cmd-response event sent for this command. The cmd-response event is sent when there is a real response ready. The rpc-reply for this operation indicates that the command was started."; } leaf timeout { type int32 { range "0..max"; } units "seconds"; default "30"; description "The number of seconds to wait for a reply from each session. The value zero indicates wait forever."; } anydata input { description "The input parameters for this YANG action. The child nodes of this node are expected to be the child nodes of the 'input' statement for the associated YANG action."; } } output { choice output-choice { leaf async-mode-started { type empty; description "Indicates the async mode was used and the operation was started successfully on at least one session."; } list session-output { key "session-name"; description "One entry represents the output from one session. If the operation was not attempted because the input parameter values (e.g., stop-time before start-time) then no entries will exist in this list and the operation will return an empty rpc-reply element instead."; leaf session-name { type nt:NcxName; description "The name of the session that the RPC operation was attempted. This name identifies an entry in the /sesmgr/sessions/session list or the /sesmgr/sessions/callhome-session list."; } choice cmd-result { leaf timeout-error { type empty; description "The operation reply was not received before the timeout."; } leaf other-error { type string; description "The error string for some other error that occurred sending the request. This case is not used if a valid response was received,"; } container data { description "The output data from the operation. The RPC operation using this grouping will augment this container with the data that is expected for that message. There will be one or more child nodes present, depending on the operation."; } // container data } // choice cmd-result } // list session-output } // choice output-choice } } // rpc invoke-action notification cmd-response { description "This event is generated by yp-controller when the invoke-rpc or invoke-action operation is used in 'async' mode. It contains the response to the requested operation or action."; leaf message-id { type string; mandatory true; description "The message-id string matching the value used in the request operation."; } choice output-choice { leaf async-mode-started { type empty; description "Indicates the async mode was used and the operation was started successfully on at least one session."; } list session-output { key "session-name"; description "One entry represents the output from one session. If the operation was not attempted because the input parameter values (e.g., stop-time before start-time) then no entries will exist in this list and the operation will return an empty rpc-reply element instead."; leaf session-name { type nt:NcxName; description "The name of the session that the RPC operation was attempted. This name identifies an entry in the /sesmgr/sessions/session list or the /sesmgr/sessions/callhome-session list."; } choice cmd-result { leaf timeout-error { type empty; description "The operation reply was not received before the timeout."; } leaf other-error { type string; description "The error string for some other error that occurred sending the request. This case is not used if a valid response was received,"; } container data { description "The output data from the operation. The RPC operation using this grouping will augment this container with the data that is expected for that message. There will be one or more child nodes present, depending on the operation."; } // container data } // choice cmd-result } // list session-output } // choice output-choice } // notification cmd-response } // module yumaworks-opsmgr
© 2023 YumaWorks, Inc. All rights reserved.