summaryrefslogtreecommitdiffstats
path: root/infra/impl/src/main/yang/honeycomb-impl.yang
blob: 46f1af8621a143341f988295deba353fa9034c33 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
module honeycomb-impl {
    yang-version 1;
    namespace "urn:opendaylight:params:xml:ns:yang:honeycomb:impl";
    prefix "hc-impl";

    import config { prefix config; revision-date 2013-04-05; }
    import opendaylight-md-sal-binding { prefix md-sal-binding; revision-date 2013-10-28;}
    import opendaylight-md-sal-dom {prefix dom;}
    import translate-api { prefix tapi; revision-date 2016-04-06; }
    import data-api { prefix dapi; revision-date 2016-04-11; }
    import notification-api { prefix hc-notif-a; revision-date 2016-06-01; }

    description
        "Service definition for honeycomb project";

    revision "2014-12-10" {
        description
            "Initial revision";
    }

    identity honeycomb {
        base config:module-type;
        config:provided-service dom:dom-broker-osgi-registry;
        config:java-name-prefix Honeycomb;
    }

    augment "/config:modules/config:module/config:configuration" {
        case honeycomb {
            when "/config:modules/config:module/config:type = 'honeycomb'";
            container dom-broker {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity dom:dom-broker-osgi-registry;
                    }
                }
            }

            container honeycomb-dom-data-broker {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity dom:dom-async-data-broker;
                    }
                }
            }

            container honeycomb-dom-notification-service {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity hc-notif-a:dom-notification-service;
                    }
                }
            }

        }
    }

    identity binding-broker-netconf {
        base config:module-type;
        config:provided-service md-sal-binding:binding-broker-osgi-registry;
        config:java-name-prefix NetconfBindingBroker;
    }

    augment "/config:modules/config:module/config:configuration" {
        case binding-broker-netconf {
            when "/config:modules/config:module/config:type = 'binding-broker-netconf'";

                container netconf-binding-broker {
                    uses config:service-ref {
                        refine type {
                            mandatory true;
                            config:required-identity md-sal-binding:binding-async-data-broker;
                        }
                    }
                }

        }
    }

    identity honeycomb-dom-data-broker {
        base config:module-type;
        config:provided-service dom:dom-async-data-broker;
        config:java-name-prefix DataBroker;
    }

    augment "/config:modules/config:module/config:configuration" {
        case honeycomb-dom-data-broker {
            when "/config:modules/config:module/config:type = 'honeycomb-dom-data-broker'";

            container config-data-tree {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity dapi:honeycomb-modifiable-data-tree;
                    }
                }
            }

            container operational-data-tree {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity dapi:honeycomb-readable-data-tree;
                    }
                }
            }

        }
    }

    identity honeycomb-context-dom-data-broker {
        base config:module-type;
        config:provided-service dom:dom-async-data-broker;
        config:java-name-prefix ContextDataBroker;
        description "DomBroker on top of context data-tree";
    }

    augment "/config:modules/config:module/config:configuration" {
        case honeycomb-context-dom-data-broker {
            when "/config:modules/config:module/config:type = 'honeycomb-context-dom-data-broker'";

            container context-data-tree {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity dapi:data-tree;
                    }
                }
            }
        }
    }

    identity netconf-monitoring-reader {
        base config:module-type;
        config:provided-service tapi:honeycomb-reader-factory;
    }

    augment "/config:modules/config:module/config:configuration" {
        case netconf-monitoring-reader {
            when "/config:modules/config:module/config:type = 'netconf-monitoring-reader'";

            container netconf-monitoring-binding-broker {
                uses config:service-ref {
                    refine type {
                        mandatory true;
                        config:required-identity md-sal-binding:binding-async-data-broker;
                    }
                }
            }

        }
    }
}