netconfcentral logo

yumaworks-db-api

HTML

yumaworks-db-api@2017-10-30



  module yumaworks-db-api {

    yang-version 1;

    namespace
      "http://yumaworks.com/ns/yumaworks-db-api";

    prefix ydb;

    import ietf-yang-patch {
      prefix yp;
    }
    import yumaworks-ycontrol {
      prefix yctl;
    }
    import yuma-ncx {
      prefix ncx;
    }

    organization "YumaWorks, Inc.";

    contact
      "Support <support at yumaworks.com>";

    description
      "YumaPro Database API Sub-Agent message definitions.

     Copyright (c) 2014 - 2017, 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 "2017-10-30" {
      description "Add getconfig message";
    }

    revision "2017-09-19" {
      description
        "Fix broken augment statement for payload";
    }

    revision "2016-08-29" {
      description "Update yp-ha-mode event";
    }

    revision "2016-07-31" {
      description
        "Add new events to support YP-HA mode changes.";
    }

    revision "2015-03-29" {
      description
        "Add edit-type parameter to edit-request.";
    }

    revision "2014-11-18" {
      description
        "Initial version for datastore access.";
    }


    augment /yctl:ycontrol/yctl:message-payload/yctl:payload/yctl:payload {
      container db-api {
        choice message-type {
          mandatory true;
          leaf register-request {
            type empty;
            description
              "Message type: subsys-request;
              Purpose: register the DB-API subsystem
              Expected Response Message: ok or error";
          }
          container edit-request {
            description
              "Message type: subsys-request;
              Purpose: Ask the main server to accept an edit request
              to be added to the running configuration, and saved to
              NV-storage unless the :startup capability is supported.

              Expected Response Message: ok or error";
            leaf target {
              type string;
              mandatory true;
              description
                "Identifies the target resource for the edit
                operation.";
            }

            leaf edit-type {
              type enumeration {
                enum "user" {
                  value 0;
                  description
                    "A user edit with access control";
                }
                enum "system" {
                  value 1;
                  description
                    "A system edit without access control";
                }
              }
              default 'user';
              description
                "Indicates whether this is a user edit or system edit.
                System edits will bypass all access control enforcement,
                including the ncx:user-write extension.";
            }

            uses yp:yang-patch;
          }  // container edit-request
          container yp-ha-mode {
            description
              "Message type: subsys-event;
              Purpose: send mode change event to the server
              Expected Response Message: none";
            choice action {
              mandatory true;
              leaf go-active {
                type empty;
                description
                  "Become the YP-HA active server.
                   All normal management operations are supported
                   in this mode.";
              }
              container go-standby {
                description
                  "Become a YP-HA standby server, and try to connect
                   to the active server 'new-active'. Only the superuser
                   can use management sesssions in this mode.";
                leaf new-active {
                  type string;
                  mandatory true;
                  description
                    "Server name of the active server to use";
                }
              }  // container go-standby
              leaf go-none {
                type empty;
                description
                  "Leave current YP-HA role and wait new role.
                   Only the superuser can use management sesssions
                   in this mode.";
              }
            }  // choice action
          }  // container yp-ha-mode
          container getconfig {
            description
              "Message type: subsys-request;
              Purpose: Ask the main server to send the running
              configuration contents

              Expected Response Message: config";
            leaf withdef {
              type boolean;
              default 'false';
              description
                "Include defaults (according to the server
                   --default-style CLI parameter) if 'true'.
                   Do not include defaults if 'false'.";
            }
          }  // container getconfig
          container config {
            ncx:root;
            description
              "Message type: server-response;
              Purpose: Provide the contents of the running
              configuration contents

              Expected Response Message: none";
          }  // container config
        }  // choice message-type
      }  // container db-api
    }
  }  // module yumaworks-db-api

Summary

  
  
Organization YumaWorks, Inc.
  
Module yumaworks-db-api
Version 2017-10-30
File yumaworks-db-api.yang
  
Prefix ydb
Namespace http://yumaworks.com/ns/yumaworks-db-api
  
Cooked /cookedmodules/yumaworks-db-api/2017-10-30
YANG /src/yumaworks-db-api@2017-10-30.yang
XSD /xsd/yumaworks-db-api@2017-10-30.xsd
  
Abstract YumaPro Database API Sub-Agent message definitions. Copyright (c) 2014 - 2017, YumaWorks, Inc. All rights reserved. Redistribu...
  
Contact
Support <support at yumaworks.com>

Description

 
YumaPro Database API Sub-Agent message definitions.

Copyright (c) 2014 - 2017, 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