-1

我正在开发一个应用程序,它接受一些输入,运行一些算法,并根据结果,使用 Opendaylight 建立到 Netconf 服务器的连接。我正在遵循 ODL Netconf 用户指南,一切正常。

以下是我的 yang 模块之一:

module openroadm-config {
namespace "urn:opendaylight:openroadm-config";
prefix "openroadm-config";

import device-cluster { prefix device-cluster; revision-date 2017-01-08; }
import ietf-yang-types { prefix ietf-yang-types; revision-date 2013-07-15; }
import ietf-inet-types { prefix ietf-inet-types; revision-date 2013-07-15; }
import ietf-netconf { prefix ietf-nc; revision-date 2011-06-01; }
import org-openroadm-common-types { prefix org-openroadm-common-types; revision-date 2017-09-29; }
import org-openroadm-resource-types { prefix org-openroadm-resource-types; revision-date 2017-09-29; }
import org-openroadm-physical-types { prefix org-openroadm-physical-types; revision-date 2017-09-29; }
import org-openroadm-user-mgmt { prefix org-openroadm-user-mgmt; revision-date 2017-09-29; }
import org-openroadm-port-types { prefix org-openroadm-port-types; revision-date 2017-09-29; }
import org-openroadm-interfaces { prefix org-openroadm-interfaces; revision-date 2017-06-26; }
import org-openroadm-swdl { prefix org-openroadm-swdl; revision-date 2017-09-29; }
import org-openroadm-equipment-states-types { prefix org-openroadm-equipment-states-types; revision-date 2017-06-26; }
import org-openroadm-device { prefix org-openroadm-device; revision-date 2017-09-29; }

revision 2018-04-12 {
    description "Initial revision";
}

grouping openroadm-device-common-details {
    uses org-openroadm-device:device-common;

    leaf max-degrees {
        config false;
        type uint16;
        description
                    "Max. number of degrees supported by device";
    }

    leaf max-srgs {
        config false;
        type uint16;
        description
                    "Max. number of SRGs in an add/drop group";
    }

    leaf max-num-bin-15min-historical-pm {
        config false;
        type uint16;
        description
                    "Max. number of bin the NE support for 15min historical PM";
    }

    leaf max-num-bin-24hour-historical-pm {
        config false;
        type uint16;
        description
                    "Max. number of bin the NE support for 24hour historical PM";
    }
}

grouping openroadm-list {

    list openroadm-device-list {
        key node-id;
        uses openroadm-device-common-details;
    }

}

container openroadm-device-list-container {
    uses openroadm-list;
}

container openroadm-data {
    uses openroadm-device-common-details;
}

rpc openroadm-set {
    input {
        uses openroadm-list;
    }
    output {
        uses device-cluster:rpc-response-status;
    }
}

rpc openroadm-get {
    input {
        list openroadm-ids {
            key openroadm-device-id;
            leaf openroadm-device-id {
                description "The openroadm device id";
                type string;
            }
        }
    }
    output {
        uses openroadm-list;
    }
}

}

默认情况下,opendaylight 中有 4 个分片——默认、toaster、库存和拓扑,以及 2 个数据存储——操作和配置。所有与拓扑相关的信息,例如 Netconf 连接器凭据都存储在拓扑分片中(我假设)。

我的问题是,我的应用程序中定义的数据存储在哪个分片中?是否可以控制我的数据进入的分片?如果是,怎么做?它与我的 yang 文件中定义的命名空间有关吗?

4

1 回答 1

2

您的数据存储在默认分片中。分片由 yang 模块命名空间控制 - 请参阅 configuration/initial/modules.conf 和 configuration/initial/module-shards.conf 文件。任何未专门放置在其自己的分片中的 yang 模块都会被放入默认分片中。

于 2018-09-11T13:52:40.460 回答