From 77fa76b4b15ec6d74920349f9a066ec4597b2585 Mon Sep 17 00:00:00 2001 From: Maros Marsalek Date: Tue, 16 Aug 2016 11:04:00 +0200 Subject: HONEYCOMB-22: Remove karaf based distribution and wiring Change-Id: I48aafb726de53b6ad3fb9b97c202f712dfa4a540 Signed-off-by: Maros Marsalek --- .gitignore | 1 + common/features-parent/pom.xml | 81 ---- .../features-parent/src/main/features/features.xml | 16 - common/karaf-parent/pom.xml | 81 ---- common/pom.xml | 2 - .../io/fd/honeycomb/data/init/RestorationType.java | 24 + .../honeycomb/data/init/RestoringInitializer.java | 1 - .../ConfigurationInitializerRegistryModule.java | 54 --- ...figurationInitializerRegistryModuleFactory.java | 14 - .../rev160407/PersistedFileInitializerModule.java | 38 -- .../PersistedFileInitializerModuleFactory.java | 13 - infra/cfg-init/src/main/yang/cfg-init.yang | 117 ----- infra/data-api/src/main/yang/data-api.yang | 38 -- .../data/impl/rev160411/ConfigDataTreeModule.java | 71 --- .../rev160411/ConfigDataTreeModuleFactory.java | 13 - .../impl/rev160411/InMemoryDataTreeModule.java | 79 ---- .../rev160411/InMemoryDataTreeModuleFactory.java | 13 - .../impl/rev160411/OperationalDataTreeModule.java | 65 --- .../OperationalDataTreeModuleFactory.java | 13 - .../rev160411/PersistingDataTreeAdapterModule.java | 38 -- .../PersistingDataTreeAdapterModuleFactory.java | 13 - infra/data-impl/src/main/yang/data-impl.yang | 179 -------- infra/features/pom.xml | 217 --------- infra/features/src/main/features/features.xml | 63 --- infra/impl/pom.xml | 48 -- .../src/main/config/context-datatree-config.xml | 144 ------ infra/impl/src/main/config/default-config.xml | 253 ----------- infra/impl/src/main/config/initializer-config.xml | 188 -------- .../impl/src/main/config/netconf-north-config.xml | 494 --------------------- .../impl/src/main/config/restconf-north-config.xml | 37 -- .../fd/honeycomb/impl/FakeBindingAwareBroker.java | 114 +++++ .../impl/NetconfMonitoringReaderFactory.java | 44 ++ .../impl/rev141210/ContextDataBrokerModule.java | 26 -- .../rev141210/ContextDataBrokerModuleFactory.java | 13 - .../honeycomb/impl/rev141210/DataBrokerModule.java | 34 -- .../impl/rev141210/DataBrokerModuleFactory.java | 13 - .../honeycomb/impl/rev141210/HoneycombModule.java | 59 --- .../impl/rev141210/HoneycombModuleFactory.java | 28 -- .../impl/rev141210/NetconfBindingBrokerModule.java | 117 ----- .../NetconfBindingBrokerModuleFactory.java | 13 - .../rev141210/NetconfMonitoringReaderModule.java | 45 -- .../NetconfMonitoringReaderModuleFactory.java | 13 - infra/impl/src/main/yang/honeycomb-impl.yang | 155 ------- infra/karaf/pom.xml | 74 --- .../PersistedFileInitializerProvider.groovy | 2 +- .../HoneycombNotification2NetconfProvider.groovy | 4 +- .../netconf/NetconfBindingBrokerProvider.groovy | 4 +- .../NetconfMonitoringReaderFactoryProvider.groovy | 4 +- .../config/honeycomb.json | 6 +- .../honeycomb-minimal-resources/config/logback.xml | 4 +- .../api/src/main/yang/notification-api.yang | 31 -- infra/notification/impl/pom.xml | 32 -- .../impl/src/main/config/default-config.xml | 71 --- .../main/config/notification-to-netconf-config.xml | 58 --- .../notification/impl/TranslationUtil.java | 104 +++++ .../HoneycombDomNotificationServiceModule.java | 27 -- ...neycombDomNotificationServiceModuleFactory.java | 13 - .../HoneycombNotificationManagerModule.java | 93 ---- .../HoneycombNotificationManagerModuleFactory.java | 13 - ...ycombNotificationToNetconfTranslatorModule.java | 155 ------- ...tificationToNetconfTranslatorModuleFactory.java | 13 - .../impl/src/main/yang/notification-impl.yang | 141 ------ .../NoetificationToNetconfModuleTest.java | 3 +- infra/pom.xml | 3 - .../translate-api/src/main/yang/translate-api.yang | 52 --- .../rev160406/DelegatingReaderRegistryModule.java | 25 -- .../DelegatingReaderRegistryModuleFactory.java | 20 - .../rev160406/DelegatingWriterRegistryModule.java | 26 -- .../DelegatingWriterRegistryModuleFactory.java | 13 - .../utils/rev160406/NoopWriterRegistryModule.java | 38 -- .../rev160406/NoopWriterRegistryModuleFactory.java | 13 - .../rev160406/RealtimeMappingContextModule.java | 23 - .../RealtimeMappingContextModuleFactory.java | 13 - .../src/main/yang/translate-utils.yang | 95 ---- packaging/rpm/persist/config/data.json | 0 packaging/rpm/persist/context/data.json | 0 v3po/features/pom.xml | 75 ---- v3po/features/src/main/features/features.xml | 43 -- v3po/pom.xml | 2 - v3po/v3po2vpp/src/main/config/default-config.xml | 346 --------------- .../io/fd/honeycomb/translate/v3po/Readme.adoc | 70 +++ .../v3po/VppClassifierHoneycombWriterFactory.java | 8 +- .../translate/v3po/cfgattrs/V3poConfiguration.java | 4 - .../InterfacesConfigurationInitializerModule.java | 24 - ...facesConfigurationInitializerModuleFactory.java | 13 - .../rev160406/InterfacesHoneycombWriterModule.java | 36 -- .../InterfacesHoneycombWriterModuleFactory.java | 13 - .../InterfacesStateHoneycombReaderModule.java | 33 -- ...nterfacesStateHoneycombReaderModuleFactory.java | 13 - .../xml/ns/yang/v3po2vpp/rev160406/Readme.adoc | 70 --- ...ppClassifierConfigurationInitializerModule.java | 24 - ...ifierConfigurationInitializerModuleFactory.java | 13 - .../VppClassifierHoneycombWriterModule.java | 33 -- .../VppClassifierHoneycombWriterModuleFactory.java | 13 - .../VppClassifierStateHoneycombReaderModule.java | 24 - ...lassifierStateHoneycombReaderModuleFactory.java | 13 - .../VppConfigurationInitializerModule.java | 24 - .../VppConfigurationInitializerModuleFactory.java | 13 - .../rev160406/VppHoneycombWriterModule.java | 32 -- .../rev160406/VppHoneycombWriterModuleFactory.java | 13 - .../VppInterfaceNotificationProducerModule.java | 28 -- ...InterfaceNotificationProducerModuleFactory.java | 13 - .../rev160406/VppStateHoneycombReaderModule.java | 99 ----- .../VppStateHoneycombReaderModuleFactory.java | 13 - .../honeycomb-minimal-resources/config/v3po.json | 1 - v3po/v3po2vpp/src/main/yang/v3po2vpp.yang | 367 --------------- vpp-common/features/pom.xml | 89 ---- vpp-common/features/src/main/features/features.xml | 33 -- .../distro/ContextsReaderFactoryProvider.groovy | 4 +- .../src/main/config/default-config.xml | 62 --- .../vpp/context/ContextsReaderFactory.java | 44 ++ .../impl/rev141210/ContextReaderModule.java | 49 -- .../impl/rev141210/ContextReaderModuleFactory.java | 13 - .../src/main/yang/context-impl.yang | 39 -- vpp-common/pom.xml | 2 - vpp-common/vpp-jvpp-cfg/pom.xml | 39 -- .../src/main/config/default-config.xml | 46 -- .../vpp/jvpp/cfg/rev160406/VppJvppImplModule.java | 45 -- .../cfg/rev160406/VppJvppImplModuleFactory.java | 13 - .../vpp-jvpp-cfg/src/main/yang/vpp-jvpp-cfg.yang | 43 -- .../util/rev160406/NamingContextImplModule.java | 26 -- .../rev160406/NamingContextImplModuleFactory.java | 13 - .../src/main/yang/vpp-util.yang | 37 -- vpp-integration/features/pom.xml | 59 --- .../features/src/main/features/features.xml | 46 -- vpp-integration/karaf/pom.xml | 92 ---- vpp-integration/pom.xml | 2 - 127 files changed, 421 insertions(+), 6103 deletions(-) delete mode 100644 common/features-parent/pom.xml delete mode 100644 common/features-parent/src/main/features/features.xml delete mode 100644 common/karaf-parent/pom.xml create mode 100644 infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestorationType.java delete mode 100644 infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModule.java delete mode 100644 infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModuleFactory.java delete mode 100644 infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModule.java delete mode 100644 infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModuleFactory.java delete mode 100644 infra/cfg-init/src/main/yang/cfg-init.yang delete mode 100644 infra/data-api/src/main/yang/data-api.yang delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModule.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModuleFactory.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModule.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModuleFactory.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModule.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModuleFactory.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModule.java delete mode 100644 infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModuleFactory.java delete mode 100644 infra/data-impl/src/main/yang/data-impl.yang delete mode 100644 infra/features/pom.xml delete mode 100644 infra/features/src/main/features/features.xml delete mode 100644 infra/impl/src/main/config/context-datatree-config.xml delete mode 100644 infra/impl/src/main/config/default-config.xml delete mode 100644 infra/impl/src/main/config/initializer-config.xml delete mode 100644 infra/impl/src/main/config/netconf-north-config.xml delete mode 100644 infra/impl/src/main/config/restconf-north-config.xml create mode 100644 infra/impl/src/main/java/io/fd/honeycomb/impl/FakeBindingAwareBroker.java create mode 100644 infra/impl/src/main/java/io/fd/honeycomb/impl/NetconfMonitoringReaderFactory.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModule.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModuleFactory.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModule.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModuleFactory.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModule.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModuleFactory.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModule.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModuleFactory.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModule.java delete mode 100644 infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModuleFactory.java delete mode 100644 infra/impl/src/main/yang/honeycomb-impl.yang delete mode 100644 infra/karaf/pom.xml delete mode 100644 infra/notification/api/src/main/yang/notification-api.yang delete mode 100644 infra/notification/impl/src/main/config/default-config.xml delete mode 100644 infra/notification/impl/src/main/config/notification-to-netconf-config.xml create mode 100644 infra/notification/impl/src/main/java/io/fd/honeycomb/notification/impl/TranslationUtil.java delete mode 100644 infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModule.java delete mode 100644 infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModuleFactory.java delete mode 100644 infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModule.java delete mode 100644 infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModuleFactory.java delete mode 100644 infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModule.java delete mode 100644 infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModuleFactory.java delete mode 100644 infra/notification/impl/src/main/yang/notification-impl.yang delete mode 100644 infra/translate-api/src/main/yang/translate-api.yang delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModule.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModuleFactory.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModule.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModuleFactory.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModule.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModuleFactory.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModule.java delete mode 100644 infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModuleFactory.java delete mode 100644 infra/translate-utils/src/main/yang/translate-utils.yang delete mode 100644 packaging/rpm/persist/config/data.json delete mode 100644 packaging/rpm/persist/context/data.json delete mode 100644 v3po/features/pom.xml delete mode 100644 v3po/features/src/main/features/features.xml delete mode 100644 v3po/v3po2vpp/src/main/config/default-config.xml create mode 100644 v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/Readme.adoc delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/Readme.adoc delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModule.java delete mode 100644 v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModuleFactory.java delete mode 100644 v3po/v3po2vpp/src/main/yang/v3po2vpp.yang delete mode 100644 vpp-common/features/pom.xml delete mode 100644 vpp-common/features/src/main/features/features.xml delete mode 100644 vpp-common/naming-context-impl/src/main/config/default-config.xml create mode 100644 vpp-common/naming-context-impl/src/main/java/io/fd/honeycomb/vpp/context/ContextsReaderFactory.java delete mode 100644 vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModule.java delete mode 100644 vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModuleFactory.java delete mode 100644 vpp-common/naming-context-impl/src/main/yang/context-impl.yang delete mode 100644 vpp-common/vpp-jvpp-cfg/pom.xml delete mode 100644 vpp-common/vpp-jvpp-cfg/src/main/config/default-config.xml delete mode 100644 vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModule.java delete mode 100644 vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModuleFactory.java delete mode 100644 vpp-common/vpp-jvpp-cfg/src/main/yang/vpp-jvpp-cfg.yang delete mode 100644 vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModule.java delete mode 100644 vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModuleFactory.java delete mode 100644 vpp-common/vpp-translate-utils/src/main/yang/vpp-util.yang delete mode 100644 vpp-integration/features/pom.xml delete mode 100644 vpp-integration/features/src/main/features/features.xml delete mode 100644 vpp-integration/karaf/pom.xml diff --git a/.gitignore b/.gitignore index f7e7ccac7..06b920b8a 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,4 @@ target .DS_Store META-INF maven-metadata-local.xml +*.log diff --git a/common/features-parent/pom.xml b/common/features-parent/pom.xml deleted file mode 100644 index b28661d8c..000000000 --- a/common/features-parent/pom.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - org.opendaylight.odlparent - features-parent - 1.6.2-Beryllium-SR2 - - - - - http://nexus.fd.io/content - - - io.fd.honeycomb.common - features-parent - 1.0.0-SNAPSHOT - 4.0.0 - pom - - - - maven-checkstyle-plugin - ${checkstyle.version} - - - check-license - - check - - none - - - - - org.apache.maven.plugins - maven-dependency-plugin - 2.10 - - - unpack-license - none - unpack - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.8 - 1.8 - - - - - - - - fdio-release - ${nexusproxy}/repositories/fd.io.release/ - - - fdio-snapshot - ${nexusproxy}/repositories/fd.io.snapshot/ - - - diff --git a/common/features-parent/src/main/features/features.xml b/common/features-parent/src/main/features/features.xml deleted file mode 100644 index 7d78e78a0..000000000 --- a/common/features-parent/src/main/features/features.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - diff --git a/common/karaf-parent/pom.xml b/common/karaf-parent/pom.xml deleted file mode 100644 index d8091f1ff..000000000 --- a/common/karaf-parent/pom.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - org.opendaylight.controller - karaf-parent - 1.6.2-Beryllium-SR2 - - - - - http://nexus.fd.io/content - - - 4.0.0 - io.fd.honeycomb.common - karaf-parent - 1.0.0-SNAPSHOT - pom - - - - maven-checkstyle-plugin - ${checkstyle.version} - - - check-license - - check - - none - - - - - org.apache.maven.plugins - maven-dependency-plugin - 2.10 - - - unpack-license - none - unpack - - - - - org.apache.maven.plugins - maven-compiler-plugin - - 1.8 - 1.8 - - - - - - - - fdio-release - ${nexusproxy}/repositories/fd.io.release/ - - - fdio-snapshot - ${nexusproxy}/repositories/fd.io.snapshot/ - - - diff --git a/common/pom.xml b/common/pom.xml index 12f87b9ce..3a53456f2 100644 --- a/common/pom.xml +++ b/common/pom.xml @@ -27,9 +27,7 @@ checkstyle api-parent - features-parent impl-parent - karaf-parent minimal-assembly-descriptor minimal-distribution-parent diff --git a/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestorationType.java b/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestorationType.java new file mode 100644 index 000000000..51b1d8bbe --- /dev/null +++ b/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestorationType.java @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2016 Cisco and/or its affiliates. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package io.fd.honeycomb.data.init; + +/** + * Type of operation to use when writing restored data + */ +public enum RestorationType { + Put, Merge +} diff --git a/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestoringInitializer.java b/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestoringInitializer.java index 54c3df787..2f3f7c99e 100644 --- a/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestoringInitializer.java +++ b/infra/cfg-init/src/main/java/io/fd/honeycomb/data/init/RestoringInitializer.java @@ -29,7 +29,6 @@ import org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFaile import org.opendaylight.controller.md.sal.dom.api.DOMDataBroker; import org.opendaylight.controller.md.sal.dom.api.DOMDataWriteTransaction; import org.opendaylight.controller.sal.core.api.model.SchemaService; -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.init.rev160407.RestorationType; import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier; import org.opendaylight.yangtools.yang.data.api.schema.ContainerNode; import org.opendaylight.yangtools.yang.data.api.schema.DataContainerChild; diff --git a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModule.java b/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModule.java deleted file mode 100644 index 3a90c5303..000000000 --- a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModule.java +++ /dev/null @@ -1,54 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.init.rev160407; - -import io.fd.honeycomb.data.init.InitializerRegistry; -import io.fd.honeycomb.data.init.InitializerRegistryImpl; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -/** -* Initializer registry, delegating initialization to a list of initializers -*/ -public class ConfigurationInitializerRegistryModule extends AbstractConfigurationInitializerRegistryModule { - - private static final Logger LOG = LoggerFactory.getLogger(ConfigurationInitializerRegistryModule.class); - - public ConfigurationInitializerRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public ConfigurationInitializerRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, ConfigurationInitializerRegistryModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - LOG.info("Config initialization started"); - - final InitializerRegistry initializer = new InitializerRegistryImpl(getInitializersDependency()); - - try { - // Initialize contexts first so that other initializers can find any relevant mapping before initializing - // configuration to what is already in VPP - getPersistedContextInitializerDependency().initialize(); - LOG.info("Persisted context restored successfully"); - // Initialize all registered initializers - initializer.initialize(); - LOG.info("Configuration initialized successfully"); - // Initialize stored configuration on top - getPersistedConfigInitializerDependency().initialize(); - LOG.info("Persisted configuration restored successfully"); - } catch (Exception e) { - LOG.warn("Failed to initialize config", e); - } - - LOG.info("Honeycomb initialized"); - - return initializer; - } - -} diff --git a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModuleFactory.java b/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModuleFactory.java deleted file mode 100644 index 461c1f01b..000000000 --- a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/ConfigurationInitializerRegistryModuleFactory.java +++ /dev/null @@ -1,14 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: vpp-cfg-init yang module local name: cfg-initializer-registry -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed May 18 14:43:49 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.init.rev160407; -public class ConfigurationInitializerRegistryModuleFactory extends - AbstractConfigurationInitializerRegistryModuleFactory { - -} diff --git a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModule.java b/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModule.java deleted file mode 100644 index b57ded9fc..000000000 --- a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModule.java +++ /dev/null @@ -1,38 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.init.rev160407; - -import io.fd.honeycomb.data.init.RestoringInitializer; -import java.nio.file.InvalidPathException; -import java.nio.file.Paths; -import org.opendaylight.controller.config.api.JmxAttributeValidationException; -import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.api.rev160411.DatatreeType; - -/** -* Initializer restoring data from a persisted file -*/ -public class PersistedFileInitializerModule extends AbstractPersistedFileInitializerModule { - public PersistedFileInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public PersistedFileInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, PersistedFileInitializerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - try { - Paths.get(getPersistFilePath()); - } catch (InvalidPathException e) { - throw new JmxAttributeValidationException("Invalid persist path", e, persistFilePathJmxAttribute); - } - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new RestoringInitializer(getSchemaServiceDependency(), Paths.get(getPersistFilePath()), - getDomDataBrokerDependency(), getRestorationType(), - getDatastoreType() == DatatreeType.Config ? LogicalDatastoreType.CONFIGURATION : LogicalDatastoreType.OPERATIONAL); - } - -} diff --git a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModuleFactory.java b/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModuleFactory.java deleted file mode 100644 index 7e703d558..000000000 --- a/infra/cfg-init/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/init/rev160407/PersistedFileInitializerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: vpp-cfg-init yang module local name: persisted-file-initializer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed May 18 13:48:52 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.init.rev160407; -public class PersistedFileInitializerModuleFactory extends AbstractPersistedFileInitializerModuleFactory { - -} diff --git a/infra/cfg-init/src/main/yang/cfg-init.yang b/infra/cfg-init/src/main/yang/cfg-init.yang deleted file mode 100644 index 8b1a4d9d1..000000000 --- a/infra/cfg-init/src/main/yang/cfg-init.yang +++ /dev/null @@ -1,117 +0,0 @@ -module cfg-init { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:data:init"; - prefix "init"; - - import config { prefix config; revision-date 2013-04-05; } - 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; } - - description - "This module contains initializers for config data tree"; - - revision "2016-04-07" { - description - "Initial revision"; - } - - identity cfg-initializer { - base "config:service-type"; - config:java-class io.fd.honeycomb.data.init.DataTreeInitializer; - } - - identity cfg-initializer-registry { - base config:module-type; - config:provided-service cfg-initializer; - config:java-name-prefix ConfigurationInitializerRegistry; - description "Initializer registry, delegating initialization to a list of initializers"; - } - - augment "/config:modules/config:module/config:configuration" { - case cfg-initializer-registry { - when "/config:modules/config:module/config:type = 'cfg-initializer-registry'"; - - list initializers { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity cfg-initializer; - } - } - } - - container persisted-context-initializer { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity cfg-initializer; - } - } - } - - container persisted-config-initializer { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity cfg-initializer; - } - } - } - } - } - - identity persisted-file-initializer { - base config:module-type; - config:provided-service cfg-initializer; - description "Initializer restoring data from a persisted file"; - } - - typedef restoration-type { - type enumeration { - enum merge; - enum put; - } - } - - augment "/config:modules/config:module/config:configuration" { - case persisted-file-initializer { - when "/config:modules/config:module/config:type = 'persisted-file-initializer'"; - - container dom-data-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dom:dom-async-data-broker; - } - } - } - - container schema-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dom:schema-service; - } - } - } - - leaf persist-file-path { - type string; - mandatory true; - } - - leaf restoration-type { - type restoration-type; - default merge; - } - - - leaf datastore-type { - type dapi:datatree-type; - mandatory true; - } - } - } - -} \ No newline at end of file diff --git a/infra/data-api/src/main/yang/data-api.yang b/infra/data-api/src/main/yang/data-api.yang deleted file mode 100644 index d09d1d371..000000000 --- a/infra/data-api/src/main/yang/data-api.yang +++ /dev/null @@ -1,38 +0,0 @@ -module data-api { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:data:api"; - prefix "dapi"; - - import config { prefix config; revision-date 2013-04-05; } - - description - "This module contains the base YANG data tree definitions - for data store modeling"; - - revision "2016-04-11" { - description - "Initial revision."; - } - - identity data-tree { - base "config:service-type"; - config:java-class org.opendaylight.yangtools.yang.data.api.schema.tree.DataTree; - } - - identity honeycomb-readable-data-tree { - base "config:service-type"; - config:java-class io.fd.honeycomb.data.ReadableDataManager; - } - - identity honeycomb-modifiable-data-tree { - base "config:service-type"; - config:java-class io.fd.honeycomb.data.ModifiableDataManager; - } - - typedef datatree-type { - type enumeration { - enum config; - enum oper; - } - } -} \ No newline at end of file diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModule.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModule.java deleted file mode 100644 index 8db0d5404..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModule.java +++ /dev/null @@ -1,71 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; - -import com.google.common.base.Optional; -import com.google.common.util.concurrent.CheckedFuture; -import io.fd.honeycomb.data.DataModification; -import io.fd.honeycomb.data.ModifiableDataManager; -import io.fd.honeycomb.data.impl.ModifiableDataTreeDelegator; -import javax.annotation.Nonnull; -import org.opendaylight.controller.md.sal.common.api.data.ReadFailedException; -import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier; -import org.opendaylight.yangtools.yang.data.api.schema.NormalizedNode; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class ConfigDataTreeModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractConfigDataTreeModule { - - private static final Logger LOG = LoggerFactory.getLogger(ConfigDataTreeModule.class); - - public ConfigDataTreeModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public ConfigDataTreeModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.ConfigDataTreeModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - LOG.debug("ConfigDataTreeModule.createInstance()"); - return new CloseableConfigDataTree( - new ModifiableDataTreeDelegator(getSerializerDependency(), getDataTreeDependency(), - getWriterRegistryBuilderDependency().build(), getContextBindingBrokerDependency())); - } - - private static final class CloseableConfigDataTree implements ModifiableDataManager, AutoCloseable { - - private final ModifiableDataTreeDelegator delegate; - - CloseableConfigDataTree(final ModifiableDataTreeDelegator delegate) { - this.delegate = delegate; - } - - @Override - public void close() throws Exception { - LOG.debug("CloseableConfigDataTree.close()"); - // NOP - } - - @Override - public DataModification newModification() { - LOG.trace("CloseableConfigDataTree.newModification"); - return delegate.newModification(); - } - - @Override - public CheckedFuture>, ReadFailedException> read( - @Nonnull final YangInstanceIdentifier path) { - return delegate.read(path); - } - } -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModuleFactory.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModuleFactory.java deleted file mode 100644 index 19baab13a..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/ConfigDataTreeModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: data-impl yang module local name: config-data-tree -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Sun Apr 10 22:07:29 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; -public class ConfigDataTreeModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractConfigDataTreeModuleFactory { - -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModule.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModule.java deleted file mode 100644 index 99e5b396c..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModule.java +++ /dev/null @@ -1,79 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; - -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.api.rev160411.DatatreeType; -import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier; -import org.opendaylight.yangtools.yang.data.api.schema.tree.*; -import org.opendaylight.yangtools.yang.data.impl.schema.tree.InMemoryDataTreeFactory; -import org.opendaylight.yangtools.yang.model.api.SchemaContext; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class InMemoryDataTreeModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractInMemoryDataTreeModule { - - private static final Logger LOG = LoggerFactory.getLogger(InMemoryDataTreeModule.class); - - public InMemoryDataTreeModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public InMemoryDataTreeModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.InMemoryDataTreeModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - LOG.debug("InMemoryConfigDataTreeModule.createInstance()"); - return new CloseableConfigDataTree(getSchemaServiceDependency().getGlobalContext(), getType()); - } - - private static class CloseableConfigDataTree implements AutoCloseable, DataTree { - private final DataTree dataTree; - - CloseableConfigDataTree(final SchemaContext schemaContext, final DatatreeType type) { - this.dataTree = InMemoryDataTreeFactory.getInstance().create( - type == DatatreeType.Config ? TreeType.CONFIGURATION : TreeType.OPERATIONAL - ); - dataTree.setSchemaContext(schemaContext); - } - - @Override - public void close() throws Exception { - // NOP - } - - @Override - public DataTreeSnapshot takeSnapshot() { - return dataTree.takeSnapshot(); - } - - @Override - public void setSchemaContext(final SchemaContext newSchemaContext) { - dataTree.setSchemaContext(newSchemaContext); - } - - @Override - public void commit(final DataTreeCandidate candidate) { - dataTree.commit(candidate); - } - - @Override - public YangInstanceIdentifier getRootPath() { - return dataTree.getRootPath(); - } - - @Override - public void validate(final DataTreeModification modification) throws DataValidationFailedException { - dataTree.validate(modification); - } - - @Override - public DataTreeCandidate prepare(final DataTreeModification modification) { - return dataTree.prepare(modification); - } - } -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModuleFactory.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModuleFactory.java deleted file mode 100644 index 34a543949..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/InMemoryDataTreeModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: data-impl yang module local name: inmemory-data-tree -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri May 13 11:10:56 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; -public class InMemoryDataTreeModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractInMemoryDataTreeModuleFactory { - -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModule.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModule.java deleted file mode 100644 index dcb0053ca..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModule.java +++ /dev/null @@ -1,65 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; - -import com.google.common.base.Optional; -import com.google.common.util.concurrent.CheckedFuture; -import io.fd.honeycomb.data.ReadableDataManager; -import io.fd.honeycomb.data.impl.ReadableDataTreeDelegator; -import javax.annotation.Nonnull; -import org.opendaylight.controller.md.sal.common.api.data.ReadFailedException; -import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier; -import org.opendaylight.yangtools.yang.data.api.schema.NormalizedNode; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class OperationalDataTreeModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractOperationalDataTreeModule { - - private static final Logger LOG = LoggerFactory.getLogger(OperationalDataTreeModule.class); - - public OperationalDataTreeModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public OperationalDataTreeModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.OperationalDataTreeModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - LOG.debug("OperationalDataTreeModule.createInstance()"); - return new CloseableOperationalDataTree( - new ReadableDataTreeDelegator(getSerializerDependency(), getSchemaServiceDependency().getGlobalContext(), - getReaderRegistryBuilderDependency().build(), getContextBindingBrokerDependency())); - } - - private static final class CloseableOperationalDataTree implements ReadableDataManager, AutoCloseable { - - private final ReadableDataTreeDelegator delegate; - - CloseableOperationalDataTree(final ReadableDataTreeDelegator delegate) { - this.delegate = delegate; - } - - @Override - public void close() throws Exception { - LOG.debug("CloseableOperationalDataTree.close()"); - // NOP - } - - @Override - public CheckedFuture>, ReadFailedException> read( - @Nonnull final YangInstanceIdentifier path) { - LOG.trace("CloseableOperationalDataTree.read path={}", path); - return delegate.read(path); - } - } -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModuleFactory.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModuleFactory.java deleted file mode 100644 index 221eabe5c..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/OperationalDataTreeModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: data-impl yang module local name: honeycomb-operational-data-tree -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Sun Apr 10 23:52:21 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; -public class OperationalDataTreeModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractOperationalDataTreeModuleFactory { - -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModule.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModule.java deleted file mode 100644 index c15feace9..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModule.java +++ /dev/null @@ -1,38 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; - -import java.nio.file.InvalidPathException; -import java.nio.file.Paths; -import org.opendaylight.controller.config.api.JmxAttributeValidationException; - -public class PersistingDataTreeAdapterModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractPersistingDataTreeAdapterModule { - public PersistingDataTreeAdapterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public PersistingDataTreeAdapterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.PersistingDataTreeAdapterModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - try { - Paths.get(getPersistFilePath()); - } catch (InvalidPathException e) { - throw new JmxAttributeValidationException("Invalid persist path", e, persistFilePathJmxAttribute); - } - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new io.fd.honeycomb.data.impl.PersistingDataTreeAdapter( - getDelegateDependency(), - getSchemaServiceDependency(), - Paths.get(getPersistFilePath())); - } - -} diff --git a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModuleFactory.java b/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModuleFactory.java deleted file mode 100644 index 0b7546c65..000000000 --- a/infra/data-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/data/impl/rev160411/PersistingDataTreeAdapterModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: data-impl yang module local name: persisting-data-tree-adapter -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Thu May 12 14:07:24 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411; -public class PersistingDataTreeAdapterModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.impl.rev160411.AbstractPersistingDataTreeAdapterModuleFactory { - -} diff --git a/infra/data-impl/src/main/yang/data-impl.yang b/infra/data-impl/src/main/yang/data-impl.yang deleted file mode 100644 index ee485538b..000000000 --- a/infra/data-impl/src/main/yang/data-impl.yang +++ /dev/null @@ -1,179 +0,0 @@ -module data-impl { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:data:impl"; - prefix "tutils"; - - 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; revision-date 2013-10-28;} - import data-api { prefix dapi; revision-date 2016-04-11; } - import translate-api { prefix tapi; revision-date 2016-04-06; } - - description - "This module contains YANG module definitions - for honeycomd data layer"; - - revision "2016-04-11" { - description - "Initial revision."; - } - - identity inmemory-data-tree { - base config:module-type; - config:provided-service dapi:data-tree; - config:java-name-prefix InMemoryDataTree; - } - - augment "/config:modules/config:module/config:configuration" { - case inmemory-data-tree { - when "/config:modules/config:module/config:type = 'inmemory-data-tree'"; - - container schema-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dom:schema-service; - } - } - } - - leaf type { - type dapi:datatree-type; - mandatory true; - } - } - } - - identity persisting-data-tree-adapter { - base config:module-type; - config:provided-service dapi:data-tree; - config:java-name-prefix PersistingDataTreeAdapter; - } - - augment "/config:modules/config:module/config:configuration" { - case persisting-data-tree-adapter { - when "/config:modules/config:module/config:type = 'persisting-data-tree-adapter'"; - - container delegate { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dapi:data-tree; - } - } - } - - container schema-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dom:schema-service; - } - } - } - - leaf persist-file-path { - type string; - mandatory true; - description "Path to a file to be used as data storage"; - } - } - } - - identity honeycomb-config-data-tree { - base config:module-type; - config:provided-service dapi:honeycomb-modifiable-data-tree; - config:java-name-prefix ConfigDataTree; - } - - augment "/config:modules/config:module/config:configuration" { - case honeycomb-config-data-tree { - when "/config:modules/config:module/config:type = 'honeycomb-config-data-tree'"; - - container data-tree { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dapi:data-tree; - } - } - } - - container serializer { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-normalized-node-serializer; - } - } - } - - container writer-registry-builder { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity tapi:honeycomb-writer-registry-builder; - } - } - } - - container context-binding-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - } - } - - identity honeycomb-operational-data-tree { - base config:module-type; - config:provided-service dapi:honeycomb-readable-data-tree; - config:java-name-prefix OperationalDataTree; - } - - augment "/config:modules/config:module/config:configuration" { - case honeycomb-operational-data-tree { - when "/config:modules/config:module/config:type = 'honeycomb-operational-data-tree'"; - - container schema-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dom:schema-service; - } - } - } - - container serializer { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-normalized-node-serializer; - } - } - } - - container reader-registry-builder { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity tapi:honeycomb-reader-registry-builder; - } - } - } - - container context-binding-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - - } - } -} \ No newline at end of file diff --git a/infra/features/pom.xml b/infra/features/pom.xml deleted file mode 100644 index 732c6ca8f..000000000 --- a/infra/features/pom.xml +++ /dev/null @@ -1,217 +0,0 @@ - - - - - io.fd.honeycomb.common - features-parent - 1.0.0-SNAPSHOT - ../../common/features-parent - - io.fd.honeycomb - honeycomb-features - 1.0.0-SNAPSHOT - ${project.artifactId} - 4.0.0 - - 3.1.1 - - - 0.8.2-Beryllium-SR2 - 1.3.2-Beryllium-SR2 - 1.3.2-Beryllium-SR2 - 1.0.2-Beryllium-SR2 - 0.8.2-Beryllium-SR2 - 0.3.2-Beryllium-SR2 - etc/opendaylight/karaf - - - - - - org.opendaylight.controller - mdsal-artifacts - ${mdsal.version} - pom - import - - - org.opendaylight.netconf - restconf-artifacts - ${restconf.version} - pom - import - - - org.opendaylight.netconf - netconf-artifacts - ${netconf.version} - pom - import - - - - - - org.opendaylight.yangtools - features-yangtools - features - ${yangtools.version} - xml - runtime - - - org.opendaylight.mdsal.model - features-mdsal-model - ${mdsal.model.version} - features - xml - runtime - - - org.opendaylight.controller - features-mdsal - features - xml - runtime - - - org.opendaylight.netconf - features-restconf - features - xml - runtime - - - org.opendaylight.netconf - features-netconf-connector - features - xml - runtime - - - org.opendaylight.dlux - features-dlux - features - ${dlux.version} - xml - runtime - - - ${project.groupId} - honeycomb-impl - ${project.version} - - - ${project.groupId} - honeycomb-impl - ${project.version} - xml - config - - - ${project.groupId} - honeycomb-impl - ${project.version} - xml - netconf - - - ${project.groupId} - honeycomb-impl - ${project.version} - xml - init - - - ${project.groupId} - honeycomb-impl - ${project.version} - xml - context - - - ${project.groupId} - honeycomb-impl - ${project.version} - xml - restconf - - - ${project.groupId} - data-api - ${project.version} - - - ${project.groupId} - data-impl - ${project.version} - - - ${project.groupId} - notification-api - ${project.version} - - - ${project.groupId} - notification-impl - ${project.version} - - - ${project.groupId} - notification-impl - ${project.version} - xml - config - - - ${project.groupId} - notification-impl - ${project.version} - xml - notification2netconf - - - ${project.groupId} - cfg-init - ${project.version} - - - ${project.groupId} - translate-api - ${project.version} - - - ${project.groupId} - translate-spi - ${project.version} - - - ${project.groupId} - translate-impl - ${project.version} - - - ${project.groupId} - translate-utils - ${project.version} - - - org.jgrapht - jgrapht-core - 0.9.2 - - - diff --git a/infra/features/src/main/features/features.xml b/infra/features/src/main/features/features.xml deleted file mode 100644 index bfc5ad8f0..000000000 --- a/infra/features/src/main/features/features.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - mvn:org.opendaylight.yangtools/features-yangtools/${yangtools.version}/xml/features - mvn:org.opendaylight.controller/features-mdsal/${mdsal.version}/xml/features - mvn:org.opendaylight.mdsal.model/features-mdsal-model/${mdsal.model.version}/xml/features - mvn:org.opendaylight.netconf/features-restconf/${restconf.version}/xml/features - mvn:org.opendaylight.netconf/features-netconf-connector/${netconf.version}/xml/features - mvn:org.opendaylight.dlux/features-dlux/${dlux.version}/xml/features - - - odl-mdsal-models - - - - odl-mdsal-broker - honeycomb-api - - odl-netconf-connector-ssh - odl-netconf-mdsal - mvn:io.fd.honeycomb/honeycomb-impl/{{VERSION}} - mvn:io.fd.honeycomb/translate-api/{{VERSION}} - mvn:io.fd.honeycomb/translate-spi/{{VERSION}} - mvn:org.jgrapht/jgrapht-core/{{VERSION}} - mvn:io.fd.honeycomb/translate-utils/{{VERSION}} - mvn:io.fd.honeycomb/data-api/{{VERSION}} - mvn:io.fd.honeycomb/data-impl/{{VERSION}} - mvn:io.fd.honeycomb/notification-api/{{VERSION}} - mvn:io.fd.honeycomb/notification-impl/{{VERSION}} - mvn:io.fd.honeycomb/translate-impl/{{VERSION}} - mvn:io.fd.honeycomb/cfg-init/{{VERSION}} - mvn:io.fd.honeycomb/honeycomb-impl/{{VERSION}}/xml/context - mvn:io.fd.honeycomb/notification-impl/{{VERSION}}/xml/config - mvn:io.fd.honeycomb/honeycomb-impl/{{VERSION}}/xml/config - mvn:io.fd.honeycomb/honeycomb-impl/{{VERSION}}/xml/init - - - - honeycomb - odl-restconf - - mvn:io.fd.honeycomb/honeycomb-impl/{{VERSION}}/xml/netconf - mvn:io.fd.honeycomb/notification-impl/{{VERSION}}/xml/notification2netconf - mvn:io.fd.honeycomb/honeycomb-impl/{{VERSION}}/xml/restconf - - - diff --git a/infra/impl/pom.xml b/infra/impl/pom.xml index 4a316ceaf..34187bf5d 100644 --- a/infra/impl/pom.xml +++ b/infra/impl/pom.xml @@ -79,52 +79,4 @@ test - - - - - - org.codehaus.mojo - build-helper-maven-plugin - - - attach-artifacts - - attach-artifact - - package - - - - ${config.file} - xml - config - - - src/main/config/netconf-north-config.xml - xml - netconf - - - src/main/config/initializer-config.xml - xml - init - - - src/main/config/context-datatree-config.xml - xml - context - - - src/main/config/restconf-north-config.xml - xml - restconf - - - - - - - - diff --git a/infra/impl/src/main/config/context-datatree-config.xml b/infra/impl/src/main/config/context-datatree-config.xml deleted file mode 100644 index d3d694dc2..000000000 --- a/infra/impl/src/main/config/context-datatree-config.xml +++ /dev/null @@ -1,144 +0,0 @@ - - - - - - - - urn:opendaylight:params:xml:ns:yang:honeycomb:impl?module=honeycomb-impl&revision=2014-12-10 - urn:honeycomb:params:xml:ns:yang:translate:utils?module=translate-utils&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:data:init?module=cfg-init&revision=2016-04-07 - urn:honeycomb:params:xml:ns:yang:data:api?module=data-api&revision=2016-04-11 - urn:honeycomb:params:xml:ns:yang:data:impl?module=data-impl&revision=2016-04-11 - urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&revision=2013-10-28 - - - - - - - - - - prefix:inmemory-data-tree - inmemory-context-data-tree - - dom:schema-service - yang-schema-service - - oper - - - - - prefix:persisting-data-tree-adapter - inmemory-persisted-context-data-tree - - prefix:data-tree - inmemory-context-data-tree - - - dom:schema-service - yang-schema-service - - data/persistence/honeycomb/context.json - - - - - prefix:honeycomb-context-dom-data-broker - honeycomb-context-data-broker - - - prefix:data-tree - inmemory-persisted-context-data-tree - - - - - - prefix:binding-forwarded-data-broker - honeycomb-context-binding-data-broker - - - dom:dom-async-data-broker - honeycomb-context-data-broker - - - dom:schema-service - yang-schema-service - - - binding:binding-dom-mapping-service - runtime-mapping-singleton - - - - - - - prefix:realtime-mapping-context - realtime-mapping-context - - binding:binding-async-data-broker - honeycomb-context-binding-data-broker - - - - - - - prefix:data-tree - - inmemory-context-data-tree - /modules/module[type='inmemory-data-tree'][name='inmemory-context-data-tree'] - - - - inmemory-persisted-context-data-tree - /modules/module[type='persisting-data-tree-adapter'][name='inmemory-persisted-context-data-tree'] - - - - - - dom:dom-async-data-broker - - honeycomb-context-data-broker - /modules/module[type='honeycomb-context-dom-data-broker'][name='honeycomb-context-data-broker'] - - - - - binding:binding-async-data-broker - - honeycomb-context-binding-data-broker - /modules/module[type='binding-forwarded-data-broker'][name='honeycomb-context-binding-data-broker'] - - - - - prefix:honeycomb-mapping-context - - realtime-mapping-context - /modules/module[type='realtime-mapping-context'][name='realtime-mapping-context'] - - - - - - diff --git a/infra/impl/src/main/config/default-config.xml b/infra/impl/src/main/config/default-config.xml deleted file mode 100644 index 14ff4ae87..000000000 --- a/infra/impl/src/main/config/default-config.xml +++ /dev/null @@ -1,253 +0,0 @@ - - - - - - urn:opendaylight:params:xml:ns:yang:honeycomb:impl?module=honeycomb-impl&revision=2014-12-10 - urn:honeycomb:params:xml:ns:yang:translate:utils?module=translate-utils&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:data:api?module=data-api&revision=2016-04-11 - urn:honeycomb:params:xml:ns:yang:data:impl?module=data-impl&revision=2016-04-11 - urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&revision=2013-10-28 - - - - - - - - prefix:delegating-reader-registry - read-registry - - - prefix:delegating-writer-registry - write-registry - - - - - prefix:inmemory-data-tree - inmemory-config-data-tree - - dom:schema-service - yang-schema-service - - config - - - - - prefix:persisting-data-tree-adapter - inmemory-persisted-config-data-tree - - prefix:data-tree - inmemory-config-data-tree - - - dom:schema-service - yang-schema-service - - data/persistence/honeycomb/config.json - - - - - - prefix:honeycomb-config-data-tree - config-data-tree - - - - - - - - prefix:data-tree - inmemory-persisted-config-data-tree - - - - prefix:binding-dom-mapping-service - runtime-mapping-singleton - - - prefix:honeycomb-writer-registry-builder - write-registry-builder - - - binding:binding-async-data-broker - honeycomb-context-binding-data-broker - - - - - - prefix:honeycomb-operational-data-tree - operational-data-tree - - dom:schema-service - yang-schema-service - - - prefix:binding-dom-mapping-service - runtime-mapping-singleton - - - prefix:honeycomb-reader-registry - read-registry - - - binding:binding-async-data-broker - honeycomb-context-binding-data-broker - - - - - - prefix:honeycomb-dom-data-broker - honeycomb-dom-data-broker - - prefix:honeycomb-modifiable-data-tree - config-data-tree - - - prefix:honeycomb-readable-data-tree - operational-data-tree - - - - - - prefix:binding-forwarded-data-broker - honeycomb-binding-data-broker - - - - dom:dom-async-data-broker - honeycomb-dom-data-broker - - - dom:schema-service - yang-schema-service - - - binding:binding-dom-mapping-service - runtime-mapping-singleton - - - - - - prefix:honeycomb - honeycomb-default - - prefix:dom-broker-osgi-registry - dom-broker - - - prefix:dom-async-data-broker - honeycomb-dom-data-broker - - - prefix:dom-notification-service - honeycomb-dom-notification-service - - - - - - - - dom:dom-async-data-broker - - honeycomb-dom-data-broker - /modules/module[type='honeycomb-dom-data-broker'][name='honeycomb-dom-data-broker'] - - - - - binding:binding-async-data-broker - - honeycomb-binding-data-broker - /modules/module[type='binding-forwarded-data-broker'][name='honeycomb-binding-data-broker'] - - - - - prefix:honeycomb-reader-registry - - read-registry - /modules/module[type='delegating-reader-registry'][name='read-registry'] - - - - prefix:honeycomb-writer-registry - - write-registry - /modules/module[type='delegating-writer-registry'][name='write-registry'] - - - - prefix:honeycomb-writer-registry-builder - - write-registry-builder - /modules/module[type='delegating-writer-registry'][name='write-registry'] - - - - - prefix:data-tree - - inmemory-config-data-tree - /modules/module[type='inmemory-data-tree'][name='inmemory-config-data-tree'] - - - - inmemory-persisted-config-data-tree - /modules/module[type='persisting-data-tree-adapter'][name='inmemory-persisted-config-data-tree'] - - - - - - prefix:honeycomb-modifiable-data-tree - - config-data-tree - /modules/module[type='honeycomb-config-data-tree'][name='config-data-tree'] - - - - - prefix:honeycomb-readable-data-tree - - operational-data-tree - /modules/module[type='honeycomb-operational-data-tree'][name='operational-data-tree'] - - - - - - dom:dom-broker-osgi-registry - - - honeycomb-dom-broker - /modules/module[type='honeycomb'][name='honeycomb-default'] - - - - - - - diff --git a/infra/impl/src/main/config/initializer-config.xml b/infra/impl/src/main/config/initializer-config.xml deleted file mode 100644 index 5265ed0d2..000000000 --- a/infra/impl/src/main/config/initializer-config.xml +++ /dev/null @@ -1,188 +0,0 @@ - - - - - - - - urn:opendaylight:params:xml:ns:yang:honeycomb:impl?module=honeycomb-impl&revision=2014-12-10 - urn:honeycomb:params:xml:ns:yang:translate:utils?module=translate-utils&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:data:init?module=cfg-init&revision=2016-04-07 - urn:honeycomb:params:xml:ns:yang:data:api?module=data-api&revision=2016-04-11 - urn:honeycomb:params:xml:ns:yang:data:impl?module=data-impl&revision=2016-04-11 - urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&revision=2013-10-28 - - - - - - - - - prefix:noop-writer-registry-builder - noop-writer-registry-builder - - - - prefix:honeycomb-config-data-tree - cfg-init-config-data-tree - - - prefix:data-tree - inmemory-config-data-tree - - - prefix:binding-dom-mapping-service - runtime-mapping-singleton - - - prefix:honeycomb-writer-registry-builder - noop-writer-registry-builder - - - binding:binding-async-data-broker - honeycomb-context-binding-data-broker - - - - - prefix:honeycomb-dom-data-broker - cfg-init-dom-data-broker - - prefix:honeycomb-modifiable-data-tree - cfg-init-config-data-tree - - - prefix:honeycomb-readable-data-tree - operational-data-tree - - - - - prefix:binding-forwarded-data-broker - cfg-init-binding-data-broker - - - dom:dom-async-data-broker - cfg-init-dom-data-broker - - - dom:schema-service - yang-schema-service - - - binding:binding-dom-mapping-service - runtime-mapping-singleton - - - - - - prefix:persisted-file-initializer - persisted-context-initializer - - dom:dom-async-data-broker - honeycomb-context-data-broker - - - dom:schema-service - yang-schema-service - - data/persistence/honeycomb/context.json - merge - oper - - - prefix:persisted-file-initializer - persisted-config-initializer - - prefix:dom-async-data-broker - honeycomb-dom-data-broker - - - dom:schema-service - yang-schema-service - - data/persistence/honeycomb/config.json - merge - config - - - - prefix:cfg-initializer-registry - initializer-registry - - prefix:cfg-initializer - persisted-context-initializer - - - prefix:cfg-initializer - persisted-config-initializer - - - - - - - - - prefix:honeycomb-writer-registry-builder - - noop-writer-registry-builder - /modules/module[type='noop-writer-registry-builder'][name='noop-writer-registry-builder'] - - - - prefix:honeycomb-modifiable-data-tree - - cfg-init-config-data-tree - /modules/module[type='honeycomb-config-data-tree'][name='cfg-init-config-data-tree'] - - - - - dom:dom-async-data-broker - - cfg-init-dom-data-broker - /modules/module[type='honeycomb-dom-data-broker'][name='cfg-init-dom-data-broker'] - - - - binding:binding-async-data-broker - - cfg-init-binding-data-broker - /modules/module[type='binding-forwarded-data-broker'][name='cfg-init-binding-data-broker'] - - - - - prefix:cfg-initializer - - persisted-context-initializer - /modules/module[type='persisted-file-initializer'][name='persisted-context-initializer'] - - - - persisted-config-initializer - /modules/module[type='persisted-file-initializer'][name='persisted-config-initializer'] - - - - - - - diff --git a/infra/impl/src/main/config/netconf-north-config.xml b/infra/impl/src/main/config/netconf-north-config.xml deleted file mode 100644 index 1a3e6a7ca..000000000 --- a/infra/impl/src/main/config/netconf-north-config.xml +++ /dev/null @@ -1,494 +0,0 @@ - - - - - - - - - - - - - prefix:inmemory-config-datastore-provider - netconf-config-store-service - - - dom:schema-service - yang-schema-service - - - - - prefix:inmemory-operational-datastore-provider - netconf-operational-store-service - - - dom:schema-service - yang-schema-service - - - - - prefix:dom-inmemory-data-broker - netconf-inmemory-data-broker - - - dom:schema-service - yang-schema-service - - - - config-dom-store-spi:config-dom-datastore - netconf-config-store-service - - - - operational-dom-store-spi:operational-dom-datastore - netconf-operational-store-service - - - - - prefix:binding-forwarded-data-broker - netconf-binding-data-broker - - - dom:dom-async-data-broker - netconf-inmemory-data-broker - - - dom:schema-service - yang-schema-service - - - binding:binding-dom-mapping-service - runtime-mapping-singleton - - - - - - prefix:binding-broker-netconf - binding-broker-netconf - - binding:binding-async-data-broker - netconf-binding-data-broker - - - - - - - prefix:netconf-mdsal-mapper - - netconf-honeycomb-mapper - - dom:schema-service - - yang-schema-service - - - - dom:yang-text-source-provider - - yang-text-source-provider - - - - dom:dom-broker-osgi-registry - - honeycomb-dom-broker - - - - prefix:netconf-mapper-registry - - honeycomb-mapper-aggregator-registry - - - - - - prefix:netconf-server-dispatcher-impl - - netconf-honeycomb-server-dispatcher - - - dom:netconf-northbound-mapper - - honeycomb-mapper-aggregator - - - - prefix:netconf-server-monitoring - - honeycomb-server-monitor - - - - prefix:netty-threadgroup - - global-boss-group - - - - prefix:netty-threadgroup - - global-worker-group - - - prefix:netty-timer - - global-timer - - - - - - prefix:netconf-mdsal-monitoring-mapper - - netconf-honeycomb-monitoring-mapper - - - prefix:netconf-server-monitoring - - honeycomb-server-monitor - - - - prefix:binding-broker-osgi-registry - - binding-broker-netconf - - - - prefix:netconf-mapper-registry - - honeycomb-mapper-aggregator-registry - - - - - - prefix:netconf-mapper-aggregator - - honeycomb-mapper-aggregator - - - - - prefix:netconf-server-monitoring-impl - - honeycomb-server-monitor - - - dom:netconf-northbound-mapper - - honeycomb-mapper-aggregator - - - - - prefix:netconf-northbound-ssh - netconf-mdsal-ssh-server - - - - - prefix:netconf-northbound-ssh - - netconf-honeycomb-ssh-server - - 2831 - - - prefix:netty-event-executor - - global-event-executor - - - - prefix:netty-threadgroup - - global-worker-group - - - - prefix:threadpool - - global-netconf-ssh-scheduled-executor - - - - prefix:netconf-server-dispatcher - - netconf-honeycomb-server-dispatcher - - - - prefix:netconf-auth-provider - - default-auth-provider - - - - - - prefix:netconf-notification-manager - - honeycomb-netconf-notification-manager - - - - - prefix:netconf-mdsal-notification-mapper - - netconf-honeycomb-notification-mapper - - - - binding:binding-async-data-broker - - netconf-binding-data-broker - - - - - prefix:binding-broker-osgi-registry - - binding-broker-netconf - - - - prefix:netconf-mapper-registry - - honeycomb-mapper-aggregator-registry - - - - prefix:netconf-notification-registry - - honeycomb-netconf-notification-manager - - - - prefix:netconf-notification-collector - - honeycomb-netconf-notification-manager - - - - - - - - prefix:netconf-northbound-tcp - - netconf-honeycomb-tcp-server - - - prefix:netconf-server-dispatcher - - netconf-honeycomb-server-dispatcher - - 7777 - - - - - prefix:netconf-monitoring-reader - netconf-monitoring-reader - - binding:binding-async-data-broker - netconf-binding-data-broker - - - - prefix:delegating-reader-registry - read-registry - - prefix:honeycomb-reader-factory - netconf-monitoring-reader - - - - - - - - - config-dom-store-spi:config-dom-datastore - - netconf-config-store-service - /modules/module[type='inmemory-config-datastore-provider'][name='netconf-config-store-service'] - - - - operational-dom-store-spi:operational-dom-datastore - - netconf-operational-store-service - /modules/module[type='inmemory-operational-datastore-provider'][name='netconf-operational-store-service'] - - - - dom:dom-async-data-broker - - netconf-inmemory-data-broker - /modules/module[type='dom-inmemory-data-broker'][name='netconf-inmemory-data-broker'] - - - - - prefix:honeycomb-reader-factory - - netconf-monitoring-reader - /modules/module[type='netconf-monitoring-reader'][name='netconf-monitoring-reader'] - - - - - - - binding:binding-async-data-broker - - netconf-binding-data-broker - /modules/module[type='binding-forwarded-data-broker'][name='netconf-binding-data-broker'] - - - - binding:binding-broker-osgi-registry - - binding-broker-netconf - /modules/module[type='binding-broker-netconf'][name='binding-broker-netconf'] - - - - - - - prefix:netconf-server-monitoring - - - honeycomb-server-monitor - /modules/module[type='netconf-server-monitoring-impl'][name='honeycomb-server-monitor'] - - - - - - prefix:netconf-northbound-mapper - - - netconf-honeycomb-mapper - /modules/module[type='netconf-mdsal-mapper'][name='netconf-honeycomb-mapper'] - - - - - prefix:netconf-northbound-mapper - - - honeycomb-mapper-aggregator - /modules/module[type='netconf-mapper-aggregator'][name='honeycomb-mapper-aggregator'] - - - - - prefix:netconf-mapper-registry - - - honeycomb-mapper-aggregator-registry - /modules/module[type='netconf-mapper-aggregator'][name='honeycomb-mapper-aggregator'] - - - - - prefix:netconf-server-dispatcher - - - netconf-honeycomb-server-dispatcher - - /modules/module[type='netconf-server-dispatcher-impl'][name='netconf-honeycomb-server-dispatcher'] - - - - - - prefix:netconf-northbound-mapper - - - netconf-honeycomb-notification-mapper - - /modules/module[type='netconf-mdsal-notification-mapper'][name='netconf-honeycomb-notification-mapper'] - - - - - - prefix:netconf-notification-collector - - - honeycomb-netconf-notification-manager - - /modules/module[type='netconf-notification-manager'][name='honeycomb-netconf-notification-manager'] - - - - - - prefix:netconf-notification-registry - - - honeycomb-netconf-notification-manager - - /modules/module[type='netconf-notification-manager'][name='honeycomb-netconf-notification-manager'] - - - - - - - - - urn:opendaylight:params:xml:ns:yang:honeycomb:impl?module=honeycomb-impl&revision=2014-12-10 - urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&revision=2013-10-28 - urn:opendaylight:params:xml:ns:yang:controller:netconf:mdsal:mapper?module=netconf-mdsal-mapper&revision=2015-01-14 - - urn:opendaylight:params:xml:ns:yang:controller:netconf:mdsal:monitoring?module=netconf-mdsal-monitoring&revision=2015-02-18 - - urn:opendaylight:params:xml:ns:yang:controller:netconf:northbound:ssh?module=netconf-northbound-ssh&revision=2015-01-14 - urn:opendaylight:params:xml:ns:yang:controller:netconf:northbound:tcp?module=netconf-northbound-tcp&revision=2015-04-23 - - urn:opendaylight:params:xml:ns:yang:controller:config:netconf:northbound:impl?module=netconf-northbound-impl&revision=2015-01-12 - - - urn:opendaylight:params:xml:ns:yang:controller:threadpool:impl:scheduled?module=threadpool-impl-scheduled&revision=2013-12-01 - - - urn:opendaylight:params:xml:ns:yang:controller:netconf:mdsal:notification?module=netconf-mdsal-notification&revision=2015-08-03 - - - diff --git a/infra/impl/src/main/config/restconf-north-config.xml b/infra/impl/src/main/config/restconf-north-config.xml deleted file mode 100644 index 00599b62c..000000000 --- a/infra/impl/src/main/config/restconf-north-config.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - rest:rest-connector-impl - rest-connector-default-impl - - - dom:dom-broker-osgi-registry - honeycomb-dom-broker - - - - - - - urn:opendaylight:params:xml:ns:yang:controller:sal:restconf:service?module=sal-restconf-service&revision=2015-07-08 - urn:opendaylight:params:xml:ns:yang:controller:md:sal:rest:connector?module=opendaylight-rest-connector&revision=2014-07-24 - - diff --git a/infra/impl/src/main/java/io/fd/honeycomb/impl/FakeBindingAwareBroker.java b/infra/impl/src/main/java/io/fd/honeycomb/impl/FakeBindingAwareBroker.java new file mode 100644 index 000000000..f11848ac7 --- /dev/null +++ b/infra/impl/src/main/java/io/fd/honeycomb/impl/FakeBindingAwareBroker.java @@ -0,0 +1,114 @@ +/* + * Copyright (c) 2016 Cisco and/or its affiliates. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package io.fd.honeycomb.impl; + +import org.opendaylight.controller.md.sal.binding.api.DataBroker; +import org.opendaylight.controller.md.sal.common.api.routing.RouteChangeListener; +import org.opendaylight.controller.sal.binding.api.BindingAwareBroker; +import org.opendaylight.controller.sal.binding.api.BindingAwareConsumer; +import org.opendaylight.controller.sal.binding.api.BindingAwareProvider; +import org.opendaylight.controller.sal.binding.api.BindingAwareService; +import org.opendaylight.controller.sal.binding.api.rpc.RpcContextIdentifier; +import org.opendaylight.yangtools.concepts.ListenerRegistration; +import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; +import org.opendaylight.yangtools.yang.binding.RpcService; +import org.osgi.framework.BundleContext; + +/** + * Binding aware broker wrapping just a DataBroker + */ +public final class FakeBindingAwareBroker implements BindingAwareBroker, AutoCloseable { + + private DataBroker netconfBindingBrokerDependency; + + public FakeBindingAwareBroker(final DataBroker netconfBindingBrokerDependency) { + + this.netconfBindingBrokerDependency = netconfBindingBrokerDependency; + } + + @Deprecated + @Override + public ConsumerContext registerConsumer(final BindingAwareConsumer bindingAwareConsumer, + final BundleContext bundleContext) { + throw new UnsupportedOperationException("Unsupported"); + } + + @Override + public ConsumerContext registerConsumer(final BindingAwareConsumer bindingAwareConsumer) { + final ConsumerContext consumerContext = new ConsumerContext() { + @Override + public T getSALService(final Class aClass) { + return aClass.equals(DataBroker.class) + ? (T) netconfBindingBrokerDependency + : null; + } + + @Override + public T getRpcService(final Class aClass) { + return null; + } + }; + bindingAwareConsumer.onSessionInitialized(consumerContext); + return consumerContext; + } + + @Override + public ProviderContext registerProvider(final BindingAwareProvider bindingAwareProvider, + final BundleContext bundleContext) { + throw new UnsupportedOperationException("Unsupported"); + } + + @Override + public ProviderContext registerProvider(final BindingAwareProvider bindingAwareProvider) { + final ProviderContext context = new ProviderContext() { + @Override + public >> ListenerRegistration registerRouteChangeListener( + final L l) { + throw new UnsupportedOperationException("Unsupported"); + } + + @Override + public T getRpcService(final Class aClass) { + throw new UnsupportedOperationException("Unsupported"); + } + + @Override + public RpcRegistration addRpcImplementation(final Class aClass, final T t) + throws IllegalStateException { + throw new UnsupportedOperationException("Unsupported"); + } + + @Override + public RoutedRpcRegistration addRoutedRpcImplementation( + final Class aClass, final T t) throws IllegalStateException { + throw new UnsupportedOperationException("Unsupported"); + } + + @Override + public T getSALService(final Class aClass) { + return aClass.equals(DataBroker.class) + ? (T) netconfBindingBrokerDependency + : null; } + }; + bindingAwareProvider.onSessionInitiated(context); + return context; + } + + @Override + public void close() throws Exception { + netconfBindingBrokerDependency = null; + } +} diff --git a/infra/impl/src/main/java/io/fd/honeycomb/impl/NetconfMonitoringReaderFactory.java b/infra/impl/src/main/java/io/fd/honeycomb/impl/NetconfMonitoringReaderFactory.java new file mode 100644 index 000000000..a299dbe3f --- /dev/null +++ b/infra/impl/src/main/java/io/fd/honeycomb/impl/NetconfMonitoringReaderFactory.java @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2016 Cisco and/or its affiliates. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package io.fd.honeycomb.impl; + +import io.fd.honeycomb.translate.read.registry.ModifiableReaderRegistryBuilder; +import io.fd.honeycomb.translate.util.read.BindingBrokerReader; +import org.opendaylight.controller.md.sal.binding.api.DataBroker; +import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.NetconfState; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.NetconfStateBuilder; +import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; + +/** + * {@link io.fd.honeycomb.translate.read.ReaderFactory} initiating reader into NETCONF's dedicated data store. + * Making NETCONF operational data available over NETCONF/RESTCONF + */ +public final class NetconfMonitoringReaderFactory implements AutoCloseable, io.fd.honeycomb.translate.read.ReaderFactory { + + private final DataBroker netconfMonitoringBindingBrokerDependency; + + public NetconfMonitoringReaderFactory(final DataBroker netconfMonitoringBindingBrokerDependency) { + this.netconfMonitoringBindingBrokerDependency = netconfMonitoringBindingBrokerDependency; + } + + @Override + public void init(final ModifiableReaderRegistryBuilder registry) { + registry.add(new BindingBrokerReader<>(InstanceIdentifier.create(NetconfState.class), + netconfMonitoringBindingBrokerDependency, + LogicalDatastoreType.OPERATIONAL, NetconfStateBuilder.class)); + } +} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModule.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModule.java deleted file mode 100644 index c2f7d688a..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModule.java +++ /dev/null @@ -1,26 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; - -import io.fd.honeycomb.data.impl.DataBroker; -import io.fd.honeycomb.data.impl.ModifiableDataTreeManager; - -public class ContextDataBrokerModule extends AbstractContextDataBrokerModule { - - public ContextDataBrokerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public ContextDataBrokerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, ContextDataBrokerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return DataBroker.create(new ModifiableDataTreeManager(getContextDataTreeDependency())); - } - -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModuleFactory.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModuleFactory.java deleted file mode 100644 index e07214b2e..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/ContextDataBrokerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po-impl yang module local name: honeycomb-context-dom-data-broker -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Mon May 16 15:27:12 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; -public class ContextDataBrokerModuleFactory extends AbstractContextDataBrokerModuleFactory { - -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModule.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModule.java deleted file mode 100644 index d97573e12..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModule.java +++ /dev/null @@ -1,34 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; - -import io.fd.honeycomb.data.impl.DataBroker; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class DataBrokerModule extends - AbstractDataBrokerModule { - - private static final Logger LOG = LoggerFactory.getLogger(DataBrokerModule.class); - - public DataBrokerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public DataBrokerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - DataBrokerModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - LOG.debug("DataBrokerModule.createInstance()"); - return DataBroker.create(getConfigDataTreeDependency(), getOperationalDataTreeDependency()); - } -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModuleFactory.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModuleFactory.java deleted file mode 100644 index 388f26c67..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/DataBrokerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po-impl yang module local name: honeycomb-dom-data-broker -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Mon Apr 11 07:53:38 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; -public class DataBrokerModuleFactory extends AbstractDataBrokerModuleFactory { - -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModule.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModule.java deleted file mode 100644 index 333219518..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModule.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (c) 2015 Cisco and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at: - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; - -import io.fd.honeycomb.impl.NorthboundFacadeHoneycombDOMBroker; -import org.opendaylight.controller.sal.core.api.AbstractProvider; -import org.opendaylight.controller.sal.core.api.Broker; -import org.opendaylight.controller.sal.core.api.model.SchemaService; - -public class HoneycombModule extends AbstractHoneycombModule { - - public HoneycombModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public HoneycombModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - HoneycombModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here - } - - @Override - public java.lang.AutoCloseable createInstance() { - - final Broker.ProviderSession providerSession = - getDomBrokerDependency().registerProvider(new AbstractProvider() { - @Override - public void onSessionInitiated(final Broker.ProviderSession providerSession) { - // NOOP - } - }); - final SchemaService schemaBiService = providerSession.getService(SchemaService.class); - - return new NorthboundFacadeHoneycombDOMBroker(getHoneycombDomDataBrokerDependency(), schemaBiService, - getHoneycombDomNotificationServiceDependency()); - } - -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModuleFactory.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModuleFactory.java deleted file mode 100644 index 2e7b0956f..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/HoneycombModuleFactory.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright (c) 2015 Cisco and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at: - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/* -* Generated file -* -* Generated from: yang module name: v3po yang module local name: v3po -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Jan 02 13:49:24 CST 2015 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; -public class HoneycombModuleFactory extends AbstractHoneycombModuleFactory { - -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModule.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModule.java deleted file mode 100644 index 4666e1166..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModule.java +++ /dev/null @@ -1,117 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; - -import org.opendaylight.controller.md.sal.binding.api.DataBroker; -import org.opendaylight.controller.md.sal.common.api.routing.RouteChangeListener; -import org.opendaylight.controller.sal.binding.api.BindingAwareBroker; -import org.opendaylight.controller.sal.binding.api.BindingAwareConsumer; -import org.opendaylight.controller.sal.binding.api.BindingAwareProvider; -import org.opendaylight.controller.sal.binding.api.BindingAwareService; -import org.opendaylight.controller.sal.binding.api.rpc.RpcContextIdentifier; -import org.opendaylight.yangtools.concepts.ListenerRegistration; -import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; -import org.opendaylight.yangtools.yang.binding.RpcService; -import org.osgi.framework.BundleContext; - -public class NetconfBindingBrokerModule extends AbstractNetconfBindingBrokerModule { - public NetconfBindingBrokerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public NetconfBindingBrokerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, NetconfBindingBrokerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new FakeBindingAwareBroker(getNetconfBindingBrokerDependency()); - } - - public static final class FakeBindingAwareBroker implements BindingAwareBroker, AutoCloseable { - - private DataBroker netconfBindingBrokerDependency; - - public FakeBindingAwareBroker(final DataBroker netconfBindingBrokerDependency) { - - this.netconfBindingBrokerDependency = netconfBindingBrokerDependency; - } - - @Deprecated - @Override - public ConsumerContext registerConsumer(final BindingAwareConsumer bindingAwareConsumer, - final BundleContext bundleContext) { - throw new UnsupportedOperationException("Unsupported"); - } - - @Override - public ConsumerContext registerConsumer(final BindingAwareConsumer bindingAwareConsumer) { - final ConsumerContext consumerContext = new ConsumerContext() { - @Override - public T getSALService(final Class aClass) { - return aClass.equals(DataBroker.class) - ? (T) netconfBindingBrokerDependency - : null; - } - - @Override - public T getRpcService(final Class aClass) { - return null; - } - }; - bindingAwareConsumer.onSessionInitialized(consumerContext); - return consumerContext; - } - - @Override - public ProviderContext registerProvider(final BindingAwareProvider bindingAwareProvider, - final BundleContext bundleContext) { - throw new UnsupportedOperationException("Unsupported"); - } - - @Override - public ProviderContext registerProvider(final BindingAwareProvider bindingAwareProvider) { - final ProviderContext context = new ProviderContext() { - @Override - public >> ListenerRegistration registerRouteChangeListener( - final L l) { - throw new UnsupportedOperationException("Unsupported"); - } - - @Override - public T getRpcService(final Class aClass) { - throw new UnsupportedOperationException("Unsupported"); - } - - @Override - public RpcRegistration addRpcImplementation(final Class aClass, final T t) - throws IllegalStateException { - throw new UnsupportedOperationException("Unsupported"); - } - - @Override - public RoutedRpcRegistration addRoutedRpcImplementation( - final Class aClass, final T t) throws IllegalStateException { - throw new UnsupportedOperationException("Unsupported"); - } - - @Override - public T getSALService(final Class aClass) { - return aClass.equals(DataBroker.class) - ? (T) netconfBindingBrokerDependency - : null; } - }; - bindingAwareProvider.onSessionInitiated(context); - return context; - } - - @Override - public void close() throws Exception { - netconfBindingBrokerDependency = null; - } - } -} - diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModuleFactory.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModuleFactory.java deleted file mode 100644 index fe9bdcf48..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfBindingBrokerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po-impl yang module local name: binding-broker-netconf -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Mar 23 10:45:48 CET 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; -public class NetconfBindingBrokerModuleFactory extends AbstractNetconfBindingBrokerModuleFactory { - -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModule.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModule.java deleted file mode 100644 index 2ea59de65..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModule.java +++ /dev/null @@ -1,45 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; - -import io.fd.honeycomb.translate.read.registry.ModifiableReaderRegistryBuilder; -import io.fd.honeycomb.translate.util.read.BindingBrokerReader; -import org.opendaylight.controller.md.sal.binding.api.DataBroker; -import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.NetconfState; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.NetconfStateBuilder; -import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; - -public class NetconfMonitoringReaderModule extends AbstractNetconfMonitoringReaderModule { - public NetconfMonitoringReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public NetconfMonitoringReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, NetconfMonitoringReaderModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new NetconfMonitoringReaderFactory(getNetconfMonitoringBindingBrokerDependency()); - } - - public static final class NetconfMonitoringReaderFactory implements AutoCloseable, io.fd.honeycomb.translate.read.ReaderFactory { - - private final DataBroker netconfMonitoringBindingBrokerDependency; - - public NetconfMonitoringReaderFactory(final DataBroker netconfMonitoringBindingBrokerDependency) { - this.netconfMonitoringBindingBrokerDependency = netconfMonitoringBindingBrokerDependency; - } - - @Override - public void init(final ModifiableReaderRegistryBuilder registry) { - registry.add(new BindingBrokerReader<>(InstanceIdentifier.create(NetconfState.class), - netconfMonitoringBindingBrokerDependency, - LogicalDatastoreType.OPERATIONAL, NetconfStateBuilder.class)); - } - } -} diff --git a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModuleFactory.java b/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModuleFactory.java deleted file mode 100644 index d5130fd53..000000000 --- a/infra/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/honeycomb/impl/rev141210/NetconfMonitoringReaderModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po-impl yang module local name: netconf-monitoring-reader -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Tue Apr 12 13:03:40 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210; -public class NetconfMonitoringReaderModuleFactory extends AbstractNetconfMonitoringReaderModuleFactory { - -} diff --git a/infra/impl/src/main/yang/honeycomb-impl.yang b/infra/impl/src/main/yang/honeycomb-impl.yang deleted file mode 100644 index 46f1af862..000000000 --- a/infra/impl/src/main/yang/honeycomb-impl.yang +++ /dev/null @@ -1,155 +0,0 @@ -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; - } - } - } - - } - } -} diff --git a/infra/karaf/pom.xml b/infra/karaf/pom.xml deleted file mode 100644 index ea42624a9..000000000 --- a/infra/karaf/pom.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - - io.fd.honeycomb.common - karaf-parent - 1.0.0-SNAPSHOT - ../../common/karaf-parent - - 4.0.0 - io.fd.honeycomb - honeycomb-karaf - 1.0.0-SNAPSHOT - ${project.artifactId} - - 3.1.1 - - - honeycomb-rest - - - - - ${project.groupId} - honeycomb-artifacts - ${project.version} - pom - import - - - - - - - org.apache.karaf.features - framework - kar - - - - ${project.groupId} - honeycomb-features - features - xml - runtime - - - - - - - org.apache.maven.plugins - maven-deploy-plugin - - true - - - - - diff --git a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/initializer/PersistedFileInitializerProvider.groovy b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/initializer/PersistedFileInitializerProvider.groovy index 9b7cfb4ae..8979272be 100644 --- a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/initializer/PersistedFileInitializerProvider.groovy +++ b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/initializer/PersistedFileInitializerProvider.groovy @@ -19,13 +19,13 @@ package io.fd.honeycomb.infra.distro.initializer import com.google.inject.Inject import groovy.transform.ToString import groovy.util.logging.Slf4j +import io.fd.honeycomb.data.init.RestorationType import io.fd.honeycomb.data.init.RestoringInitializer import io.fd.honeycomb.infra.distro.ProviderTrait import io.fd.honeycomb.infra.distro.cfgattrs.HoneycombConfiguration import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType import org.opendaylight.controller.md.sal.dom.api.DOMDataBroker import org.opendaylight.controller.sal.core.api.model.SchemaService -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.data.init.rev160407.RestorationType import java.nio.file.Paths /** diff --git a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/HoneycombNotification2NetconfProvider.groovy b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/HoneycombNotification2NetconfProvider.groovy index 726dfb5af..7e4453ef1 100644 --- a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/HoneycombNotification2NetconfProvider.groovy +++ b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/HoneycombNotification2NetconfProvider.groovy @@ -26,7 +26,7 @@ import io.fd.honeycomb.notification.impl.NotificationProducerRegistry import org.opendaylight.controller.md.sal.dom.broker.impl.DOMNotificationRouter import org.opendaylight.controller.sal.core.api.model.SchemaService import org.opendaylight.netconf.notifications.NetconfNotificationCollector -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.HoneycombNotificationToNetconfTranslatorModule as Mirror +import io.fd.honeycomb.notification.impl.TranslationUtil import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netconf.notification._1._0.rev080714.StreamNameType import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netmod.notification.rev080714.netconf.streams.StreamBuilder import org.opendaylight.yangtools.yang.model.api.SchemaPath @@ -63,7 +63,7 @@ class HoneycombNotification2NetconfProvider extends ProviderTrait log.debug "Propagating notification: {} into NETCONF", notif.type - netconfNotifReg.onNotification(streamType, Mirror.notificationToXml(notif, schemaService.globalContext)) + netconfNotifReg.onNotification(streamType, TranslationUtil.notificationToXml(notif, schemaService.globalContext)) } // NotificationManager is used to provide list of available notifications (which are all of the notifications registered) diff --git a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfBindingBrokerProvider.groovy b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfBindingBrokerProvider.groovy index 8c5dcab01..ebf6782c1 100644 --- a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfBindingBrokerProvider.groovy +++ b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfBindingBrokerProvider.groovy @@ -23,7 +23,7 @@ import groovy.util.logging.Slf4j import io.fd.honeycomb.infra.distro.ProviderTrait import org.opendaylight.controller.md.sal.binding.api.DataBroker import org.opendaylight.controller.sal.binding.api.BindingAwareBroker -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210.NetconfBindingBrokerModule +import io.fd.honeycomb.impl.FakeBindingAwareBroker /** * Mirror of {@link org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210.NetconfBindingBrokerModule} @@ -37,5 +37,5 @@ class NetconfBindingBrokerProvider extends ProviderTrait { DataBroker dataBroker @Override - def create() { new NetconfBindingBrokerModule.FakeBindingAwareBroker(dataBroker) } + def create() { new FakeBindingAwareBroker(dataBroker) } } diff --git a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfMonitoringReaderFactoryProvider.groovy b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfMonitoringReaderFactoryProvider.groovy index fee1944f4..6c58f8b89 100644 --- a/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfMonitoringReaderFactoryProvider.groovy +++ b/infra/minimal-distribution/src/main/java/io/fd/honeycomb/infra/distro/netconf/NetconfMonitoringReaderFactoryProvider.groovy @@ -23,7 +23,7 @@ import groovy.util.logging.Slf4j import io.fd.honeycomb.infra.distro.ProviderTrait import io.fd.honeycomb.translate.read.ReaderFactory import org.opendaylight.controller.md.sal.binding.api.DataBroker -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.honeycomb.impl.rev141210.NetconfMonitoringReaderModule +import io.fd.honeycomb.impl.NetconfMonitoringReaderFactory @Slf4j @ToString @@ -33,5 +33,5 @@ class NetconfMonitoringReaderFactoryProvider extends ProviderTrait - ~/honeycomb/logs/honeycomb.log + /var/log/honeycomb/honeycomb.log - ~/honeycomb/logs/honeycomb.%d.log.zip + /var/log/honeycomb/logs/honeycomb.%d.log.zip 1 diff --git a/infra/notification/api/src/main/yang/notification-api.yang b/infra/notification/api/src/main/yang/notification-api.yang deleted file mode 100644 index f0331bc07..000000000 --- a/infra/notification/api/src/main/yang/notification-api.yang +++ /dev/null @@ -1,31 +0,0 @@ -module notification-api { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:notification:api"; - prefix "hc-notif-a"; - - import config { prefix config; revision-date 2013-04-05; } - - description - "Module definition for honeycomb notification service APIs"; - - revision "2016-06-01" { - description - "Initial revision"; - } - - identity honeycomb-notification-collector { - base "config:service-type"; - config:java-class io.fd.honeycomb.notification.NotificationCollector; - } - - identity dom-notification-service { - base "config:service-type"; - config:java-class org.opendaylight.controller.md.sal.dom.broker.impl.DOMNotificationRouter; - } - - identity honeycomb-notification-producer { - base "config:service-type"; - config:java-class io.fd.honeycomb.notification.ManagedNotificationProducer; - } - -} diff --git a/infra/notification/impl/pom.xml b/infra/notification/impl/pom.xml index 9fa542422..bc0a78e6e 100644 --- a/infra/notification/impl/pom.xml +++ b/infra/notification/impl/pom.xml @@ -57,36 +57,4 @@ test - - - - - org.codehaus.mojo - build-helper-maven-plugin - - - attach-artifacts - - attach-artifact - - package - - - - ${config.file} - xml - config - - - src/main/config/notification-to-netconf-config.xml - xml - notification2netconf - - - - - - - - diff --git a/infra/notification/impl/src/main/config/default-config.xml b/infra/notification/impl/src/main/config/default-config.xml deleted file mode 100644 index 2b91de47f..000000000 --- a/infra/notification/impl/src/main/config/default-config.xml +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - urn:honeycomb:params:xml:ns:yang:notification:impl?module=notification-impl&revision=2016-06-01 - - - - - - - - prefix:honeycomb-dom-notification-service - honeycomb-dom-notification-service - 1024 - - - - - prefix:honeycomb-notification-manager - honeycomb-notification-manager - - binding-impl:binding-dom-mapping-service - runtime-mapping-singleton - - - prefix:dom-notification-service - honeycomb-dom-notification-service - - - - - - - - - - - prefix:dom-notification-service - - honeycomb-dom-notification-service - /modules/module[type='honeycomb-dom-notification-service'][name='honeycomb-dom-notification-service'] - - - - prefix:honeycomb-notification-collector - - honeycomb-notification-manager - /modules/module[type='honeycomb-notification-manager'][name='honeycomb-notification-manager'] - - - - - - - - diff --git a/infra/notification/impl/src/main/config/notification-to-netconf-config.xml b/infra/notification/impl/src/main/config/notification-to-netconf-config.xml deleted file mode 100644 index d64de6413..000000000 --- a/infra/notification/impl/src/main/config/notification-to-netconf-config.xml +++ /dev/null @@ -1,58 +0,0 @@ - - - - - - urn:honeycomb:params:xml:ns:yang:notification:impl?module=notification-impl&revision=2016-06-01 - - - - - - - prefix:honeycomb-notification-to-netconf-translator - honeycomb-notification-to-netconf-translator - - - prefix:netconf-notification-registry - - honeycomb-netconf-notification-manager - - - - prefix:netconf-notification-collector - - honeycomb-netconf-notification-manager - - - dom:schema-service - yang-schema-service - - - prefix:honeycomb-notification-collector - honeycomb-notification-manager - - - prefix:dom-notification-service - honeycomb-dom-notification-service - - honeycomb - All notifications received by honeycomb's plugins - - - - - diff --git a/infra/notification/impl/src/main/java/io/fd/honeycomb/notification/impl/TranslationUtil.java b/infra/notification/impl/src/main/java/io/fd/honeycomb/notification/impl/TranslationUtil.java new file mode 100644 index 000000000..e53d59196 --- /dev/null +++ b/infra/notification/impl/src/main/java/io/fd/honeycomb/notification/impl/TranslationUtil.java @@ -0,0 +1,104 @@ +/* + * Copyright (c) 2016 Cisco and/or its affiliates. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package io.fd.honeycomb.notification.impl; + +import java.io.IOException; +import javax.xml.stream.XMLOutputFactory; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamWriter; +import javax.xml.transform.dom.DOMResult; +import org.opendaylight.controller.config.util.xml.XmlUtil; +import org.opendaylight.controller.md.sal.dom.api.DOMNotification; +import org.opendaylight.netconf.notifications.NetconfNotification; +import org.opendaylight.yangtools.yang.common.QName; +import org.opendaylight.yangtools.yang.data.api.schema.DataContainerChild; +import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeStreamWriter; +import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter; +import org.opendaylight.yangtools.yang.data.impl.codec.xml.XMLStreamNormalizedNodeStreamWriter; +import org.opendaylight.yangtools.yang.model.api.SchemaContext; +import org.opendaylight.yangtools.yang.model.api.SchemaPath; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.w3c.dom.Document; +import org.w3c.dom.Element; + +public final class TranslationUtil { + + public TranslationUtil() {} + + private static final Logger LOG = LoggerFactory.getLogger(TranslationUtil.class); + private static final XMLOutputFactory XML_FACTORY; + + static { + XML_FACTORY = XMLOutputFactory.newFactory(); + XML_FACTORY.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, false); + } + + /** + * Transform {@link org.opendaylight.mdsal.dom.api.DOMNotification} into an XML based {@link NetconfNotification}. + */ + public static NetconfNotification notificationToXml(final DOMNotification domNotification, final SchemaContext ctx) { + + LOG.trace("Transforming notification: {} into XML", domNotification.getType()); + + final SchemaPath type = domNotification.getType(); + final QName notificationQName = type.getLastComponent(); + final DOMResult result = prepareDomResultForRpcRequest(notificationQName); + + try { + writeNormalizedRpc(domNotification, result, type, ctx); + } catch (final XMLStreamException | IOException | IllegalStateException e) { + LOG.warn("Unable to transform notification: {} into XML", domNotification.getType(), e); + throw new IllegalArgumentException("Unable to serialize " + type, e); + } + + final Document node = result.getNode().getOwnerDocument(); + return new NetconfNotification(node); + } + + private static DOMResult prepareDomResultForRpcRequest(final QName notificationQName) { + final Document document = XmlUtil.newDocument(); + final Element notificationElement = + document.createElementNS(notificationQName.getNamespace().toString(), notificationQName.getLocalName()); + document.appendChild(notificationElement); + return new DOMResult(notificationElement); + } + + private static void writeNormalizedRpc(final DOMNotification normalized, final DOMResult result, + final SchemaPath schemaPath, final SchemaContext baseNetconfCtx) + throws IOException, XMLStreamException { + final XMLStreamWriter writer = XML_FACTORY.createXMLStreamWriter(result); + try { + try (final NormalizedNodeStreamWriter normalizedNodeStreamWriter = + XMLStreamNormalizedNodeStreamWriter.create(writer, baseNetconfCtx, schemaPath)) { + try (final NormalizedNodeWriter normalizedNodeWriter = + NormalizedNodeWriter.forStreamWriter(normalizedNodeStreamWriter)) { + for (DataContainerChild dataContainerChild : normalized.getBody().getValue()) { + normalizedNodeWriter.write(dataContainerChild); + } + normalizedNodeWriter.flush(); + } + } + } finally { + try { + writer.close(); + } catch (final Exception e) { + LOG.warn("Unable to close resource properly. Ignoring", e); + } + } + } +} diff --git a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModule.java b/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModule.java deleted file mode 100644 index 9a9c7def0..000000000 --- a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModule.java +++ /dev/null @@ -1,27 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; - -import org.opendaylight.controller.config.api.JmxAttributeValidationException; -import org.opendaylight.controller.md.sal.dom.broker.impl.DOMNotificationRouter; - -public class HoneycombDomNotificationServiceModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.AbstractHoneycombDomNotificationServiceModule { - public HoneycombDomNotificationServiceModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public HoneycombDomNotificationServiceModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.HoneycombDomNotificationServiceModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - JmxAttributeValidationException.checkCondition(getQueueDepth() > 0, "Queue depth must be > 0", queueDepthJmxAttribute); - } - - @Override - public java.lang.AutoCloseable createInstance() { - // Create DOMNotificationRouter to do the heavy lifting for HoneycombNotificationCollector - // It creates executor internally - return DOMNotificationRouter.create(getQueueDepth()); - } - -} diff --git a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModuleFactory.java b/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModuleFactory.java deleted file mode 100644 index d3603acb3..000000000 --- a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombDomNotificationServiceModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: notification-impl yang module local name: honeycomb-dom-notification-service -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Jun 08 09:49:08 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; -public class HoneycombDomNotificationServiceModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.AbstractHoneycombDomNotificationServiceModuleFactory { - -} diff --git a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModule.java b/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModule.java deleted file mode 100644 index 056b38798..000000000 --- a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModule.java +++ /dev/null @@ -1,93 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; - -import io.fd.honeycomb.notification.NotificationCollector; -import io.fd.honeycomb.notification.NotificationProducer; -import io.fd.honeycomb.notification.impl.HoneycombNotificationCollector; -import io.fd.honeycomb.notification.impl.NotificationProducerRegistry; -import io.fd.honeycomb.notification.impl.NotificationProducerTracker; -import java.util.Collection; -import org.opendaylight.controller.md.sal.binding.impl.BindingDOMNotificationPublishServiceAdapter; -import org.opendaylight.controller.md.sal.binding.impl.BindingToNormalizedNodeCodec; -import org.opendaylight.controller.md.sal.dom.broker.impl.DOMNotificationRouter; -import org.opendaylight.yangtools.yang.binding.Notification; - -public class HoneycombNotificationManagerModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.AbstractHoneycombNotificationManagerModule { - - public HoneycombNotificationManagerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public HoneycombNotificationManagerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.HoneycombNotificationManagerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - final DOMNotificationRouter notificationRouter = getDomNotificationServiceDependency(); - - // Create the registry to keep track of what's registered - final NotificationProducerRegistry notificationProducerRegistry = - new NotificationProducerRegistry(getNotificationProducersDependency()); - - // Create BA version of notification service (implementation is free from ODL) - final BindingToNormalizedNodeCodec codec = getRuntimeMappingCodecDependency(); - final BindingDOMNotificationPublishServiceAdapter bindingDOMNotificationPublishServiceAdapter = - new BindingDOMNotificationPublishServiceAdapter(codec, notificationRouter); - - // Create Collector on top of BA notification service and registry - final HoneycombNotificationCollector honeycombNotificationCollector = - new HoneycombNotificationCollector(bindingDOMNotificationPublishServiceAdapter, notificationProducerRegistry); - - // Create tracker, responsible for starting and stopping registered notification producers whenever necessary - final NotificationProducerTracker notificationProducerTracker = - new NotificationProducerTracker(notificationProducerRegistry, honeycombNotificationCollector, - notificationRouter); - - // TODO wire with restconf - // DOMNotificationService is already provided by DOMBroker injected into RESTCONF, however RESTCONF - // only supports data-change notification, nothing else. So currently its impossible. - - return new CloseableCollector(honeycombNotificationCollector, () -> { - // Close all resources in order opposite to instantiation - notificationProducerTracker.close(); - honeycombNotificationCollector.close(); - bindingDOMNotificationPublishServiceAdapter.close(); - // notificationProducerRegistry; no close, it's just a collection - }); - } - - /** - * NotificationCollector wrapper in which close method execution can be injected - */ - private class CloseableCollector implements AutoCloseable, NotificationCollector, NotificationProducer { - - private final HoneycombNotificationCollector honeycombNotificationCollector; - private final AutoCloseable resources; - - CloseableCollector(final HoneycombNotificationCollector honeycombNotificationCollector, - final AutoCloseable resources) { - this.honeycombNotificationCollector = honeycombNotificationCollector; - this.resources = resources; - } - - @Override - public void close() throws Exception { - resources.close(); - } - - @Override - public void onNotification(final Notification notification) { - honeycombNotificationCollector.onNotification(notification); - } - - @Override - public Collection> getNotificationTypes() { - return honeycombNotificationCollector.getNotificationTypes(); - } - } -} diff --git a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModuleFactory.java b/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModuleFactory.java deleted file mode 100644 index b12b70017..000000000 --- a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationManagerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: notification-impl yang module local name: honeycomb-notification-manager -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Jun 01 16:08:01 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; -public class HoneycombNotificationManagerModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.AbstractHoneycombNotificationManagerModuleFactory { - -} diff --git a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModule.java b/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModule.java deleted file mode 100644 index a6f625589..000000000 --- a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModule.java +++ /dev/null @@ -1,155 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; - -import io.fd.honeycomb.notification.NotificationCollector; -import io.fd.honeycomb.notification.impl.NotificationProducerRegistry; -import java.io.IOException; -import java.util.Set; -import java.util.stream.Collectors; -import javax.xml.stream.XMLOutputFactory; -import javax.xml.stream.XMLStreamException; -import javax.xml.stream.XMLStreamWriter; -import javax.xml.transform.dom.DOMResult; -import org.opendaylight.controller.config.api.JmxAttributeValidationException; -import org.opendaylight.controller.config.util.xml.XmlUtil; -import org.opendaylight.controller.md.sal.dom.api.DOMNotification; -import org.opendaylight.controller.md.sal.dom.api.DOMNotificationListener; -import org.opendaylight.controller.sal.core.api.model.SchemaService; -import org.opendaylight.netconf.notifications.NetconfNotification; -import org.opendaylight.netconf.notifications.NotificationPublisherRegistration; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netconf.notification._1._0.rev080714.StreamNameType; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.netmod.notification.rev080714.netconf.streams.StreamBuilder; -import org.opendaylight.yangtools.concepts.ListenerRegistration; -import org.opendaylight.yangtools.yang.common.QName; -import org.opendaylight.yangtools.yang.data.api.schema.DataContainerChild; -import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeStreamWriter; -import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeWriter; -import org.opendaylight.yangtools.yang.data.impl.codec.xml.XMLStreamNormalizedNodeStreamWriter; -import org.opendaylight.yangtools.yang.model.api.SchemaContext; -import org.opendaylight.yangtools.yang.model.api.SchemaPath; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; -import org.w3c.dom.Document; -import org.w3c.dom.Element; - -public class HoneycombNotificationToNetconfTranslatorModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.AbstractHoneycombNotificationToNetconfTranslatorModule { - - private static final Logger LOG = LoggerFactory.getLogger(HoneycombNotificationToNetconfTranslatorModule.class); - - public HoneycombNotificationToNetconfTranslatorModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public HoneycombNotificationToNetconfTranslatorModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.HoneycombNotificationToNetconfTranslatorModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - JmxAttributeValidationException.checkCondition(!getNetconfStreamName().isEmpty(), - "Stream name cannot be empty", netconfStreamNameJmxAttribute); - JmxAttributeValidationException.checkCondition(!getNetconfStreamDescription().isEmpty(), - "Stream description cannot be empty", netconfStreamDescriptionJmxAttribute); - } - - @Override - public java.lang.AutoCloseable createInstance() { - final SchemaService schemaService = getSchemaServiceDependency(); - final StreamNameType streamType = new StreamNameType(getNetconfStreamName()); - final NotificationCollector hcNotificationCollector = getHoneycombNotificationCollectorDependency(); - - // Register as NETCONF notification publisher under configured name - final NotificationPublisherRegistration netconfNotificationProducerReg = - getNetconfNotificationCollectorDependency().registerNotificationPublisher(new StreamBuilder() - .setName(streamType) - .setReplaySupport(false) - .setDescription(getNetconfStreamDescription()).build()); - - // Notification Translator, get notification from HC producers and put into NETCONF notification collector - final DOMNotificationListener domNotificationListener = - notification -> { - LOG.debug("Propagating notification: {} into NETCONF", notification.getType()); - netconfNotificationProducerReg.onNotification(streamType, notificationToXml(notification, schemaService.getGlobalContext())); - }; - - // NotificationManager is used to provide list of available notifications (which are all of the notifications registered) - // TODO make available notifications configurable here so that any number of notification streams for NETCONF - // can be configured on top of a single notification manager - LOG.debug("Current notifications to be exposed over NETCONF: {}", hcNotificationCollector.getNotificationTypes()); - final Set currentNotificationSchemaPaths = hcNotificationCollector.getNotificationTypes() - .stream() - .map(NotificationProducerRegistry::getQName) - .map(qName -> SchemaPath.create(true, qName)) - .collect(Collectors.toSet()); - - // Register as listener to HC's DOM notification service - // TODO This should only be triggered when NETCONF notifications are activated - // Because this way we actually start all notification producers - // final Collection notificationQNames = - final ListenerRegistration domNotificationListenerReg = getDomNotificationServiceDependency() - .registerNotificationListener(domNotificationListener, currentNotificationSchemaPaths); - - LOG.info("Exposing NETCONF notification stream: {}", streamType.getValue()); - return () -> { - domNotificationListenerReg.close(); - netconfNotificationProducerReg.close(); - }; - } - - public static NetconfNotification notificationToXml(final DOMNotification domNotification, final SchemaContext ctx) { - LOG.trace("Transforming notification: {} into XML", domNotification.getType()); - - final SchemaPath type = domNotification.getType(); - final QName notificationQName = type.getLastComponent(); - final DOMResult result = prepareDomResultForRpcRequest(notificationQName); - - try { - writeNormalizedRpc(domNotification, result, type, ctx); - } catch (final XMLStreamException | IOException | IllegalStateException e) { - LOG.warn("Unable to transform notification: {} into XML", domNotification.getType(), e); - throw new IllegalArgumentException("Unable to serialize " + type, e); - } - - final Document node = result.getNode().getOwnerDocument(); - return new NetconfNotification(node); - } - - private static DOMResult prepareDomResultForRpcRequest(final QName notificationQName) { - final Document document = XmlUtil.newDocument(); - final Element notificationElement = - document.createElementNS(notificationQName.getNamespace().toString(), notificationQName.getLocalName()); - document.appendChild(notificationElement); - return new DOMResult(notificationElement); - } - - private static final XMLOutputFactory XML_FACTORY; - - static { - XML_FACTORY = XMLOutputFactory.newFactory(); - XML_FACTORY.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, false); - } - - private static void writeNormalizedRpc(final DOMNotification normalized, final DOMResult result, - final SchemaPath schemaPath, final SchemaContext baseNetconfCtx) - throws IOException, XMLStreamException { - final XMLStreamWriter writer = XML_FACTORY.createXMLStreamWriter(result); - try { - try (final NormalizedNodeStreamWriter normalizedNodeStreamWriter = - XMLStreamNormalizedNodeStreamWriter.create(writer, baseNetconfCtx, schemaPath)) { - try (final NormalizedNodeWriter normalizedNodeWriter = - NormalizedNodeWriter.forStreamWriter(normalizedNodeStreamWriter)) { - for (DataContainerChild dataContainerChild : normalized.getBody().getValue()) { - normalizedNodeWriter.write(dataContainerChild); - } - normalizedNodeWriter.flush(); - } - } - } finally { - try { - writer.close(); - } catch (final Exception e) { - LOG.warn("Unable to close resource properly. Ignoring", e); - } - } - } - -} diff --git a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModuleFactory.java b/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModuleFactory.java deleted file mode 100644 index 336223040..000000000 --- a/infra/notification/impl/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/HoneycombNotificationToNetconfTranslatorModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: notification-impl yang module local name: honeycomb-notification-to-netconf-translator -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Thu Jun 02 14:39:23 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; -public class HoneycombNotificationToNetconfTranslatorModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601.AbstractHoneycombNotificationToNetconfTranslatorModuleFactory { - -} diff --git a/infra/notification/impl/src/main/yang/notification-impl.yang b/infra/notification/impl/src/main/yang/notification-impl.yang deleted file mode 100644 index 84899751c..000000000 --- a/infra/notification/impl/src/main/yang/notification-impl.yang +++ /dev/null @@ -1,141 +0,0 @@ -module notification-impl { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:notification:impl"; - prefix "hc-notif-i"; - - import config { prefix config; revision-date 2013-04-05; } - import netconf-northbound-notification { prefix notify-api; revision-date 2015-08-06; } - import notification-api { prefix hc-notif-a; revision-date 2016-06-01; } - import opendaylight-md-sal-dom { prefix dom; revision-date 2013-10-28;} - import opendaylight-sal-binding-broker-impl { prefix binding-impl; revision-date 2013-10-28;} - - description - "Module definition for honeycomb notification implementations"; - - revision "2016-06-01" { - description - "Initial revision"; - } - - identity honeycomb-notification-manager { - base config:module-type; - config:java-name-prefix HoneycombNotificationManager; - config:provided-service hc-notif-a:honeycomb-notification-collector; - } - - augment "/config:modules/config:module/config:configuration" { - case honeycomb-notification-manager { - when "/config:modules/config:module/config:type = 'honeycomb-notification-manager'"; - - container runtime-mapping-codec { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity binding-impl:binding-dom-mapping-service; - } - } - } - - container dom-notification-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity hc-notif-a:dom-notification-service; - } - } - } - - list notification-producers { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity hc-notif-a:honeycomb-notification-producer; - } - } - } - - } - } - - identity honeycomb-dom-notification-service { - base config:module-type; - config:provided-service hc-notif-a:dom-notification-service; - } - - augment "/config:modules/config:module/config:configuration" { - case honeycomb-dom-notification-service { - when "/config:modules/config:module/config:type = 'honeycomb-dom-notification-service'"; - - leaf queue-depth { - type uint16; - description "Size of the queue for outgoing notifications"; - } - } - } - - identity honeycomb-notification-to-netconf-translator { - base config:module-type; - config:java-name-prefix HoneycombNotificationToNetconfTranslator; - } - - augment "/config:modules/config:module/config:configuration" { - case honeycomb-notification-to-netconf-translator { - when "/config:modules/config:module/config:type = 'honeycomb-notification-to-netconf-translator'"; - - container netconf-notification-collector { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity notify-api:netconf-notification-collector; - } - } - } - container honeycomb-notification-collector { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity hc-notif-a:honeycomb-notification-collector; - } - } - } - container netconf-notification-registry { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity notify-api:netconf-notification-registry; - } - } - } - container schema-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity dom:schema-service; - } - } - } - container dom-notification-service { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity hc-notif-a:dom-notification-service; - } - } - } - - leaf netconf-stream-name { - type string; - mandatory true; - description "Name of the stream under which all the registered notifications should be emitted"; - } - - leaf netconf-stream-description { - type string; - mandatory true; - description "Description for the stream under which all the registered notifications should be emitted"; - } - - } - } - -} diff --git a/infra/notification/impl/src/test/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/NoetificationToNetconfModuleTest.java b/infra/notification/impl/src/test/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/NoetificationToNetconfModuleTest.java index ccfb4bb9d..d9b487be7 100644 --- a/infra/notification/impl/src/test/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/NoetificationToNetconfModuleTest.java +++ b/infra/notification/impl/src/test/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/notification/impl/rev160601/NoetificationToNetconfModuleTest.java @@ -15,6 +15,7 @@ */ package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.notification.impl.rev160601; +import io.fd.honeycomb.notification.impl.TranslationUtil; import javax.annotation.Nonnull; import org.hamcrest.CoreMatchers; import org.junit.Assert; @@ -61,7 +62,7 @@ public class NoetificationToNetconfModuleTest { public void notificationToXml() throws Exception { final ModuleInfoBackedContext moduleInfoBackedContext = getModuleInfoBackedCOntext(); - final NetconfNotification netconfNotification = HoneycombNotificationToNetconfTranslatorModule + final NetconfNotification netconfNotification = TranslationUtil .notificationToXml(notification, moduleInfoBackedContext.getSchemaContext()); final String notificationString = netconfNotification.toString(); diff --git a/infra/pom.xml b/infra/pom.xml index 9f9ea549f..0f0662590 100644 --- a/infra/pom.xml +++ b/infra/pom.xml @@ -42,9 +42,6 @@ cfg-init impl minimal-distribution - - - artifacts it diff --git a/infra/translate-api/src/main/yang/translate-api.yang b/infra/translate-api/src/main/yang/translate-api.yang deleted file mode 100644 index 133662289..000000000 --- a/infra/translate-api/src/main/yang/translate-api.yang +++ /dev/null @@ -1,52 +0,0 @@ -module translate-api { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:translate:api"; - prefix "tapi"; - - import config { prefix config; revision-date 2013-04-05; } - - description - "This module contains the base YANG definitions for - readers/writers plugged into a honeycomb"; - - revision "2016-04-06" { - description - "Initial revision."; - } - - identity honeycomb-reader-factory { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.read.ReaderFactory; - } - - identity honeycomb-reader-registry { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.read.registry.ModifiableReaderRegistryBuilder; - } - - identity honeycomb-reader-registry-builder { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.read.registry.ReaderRegistryBuilder; - } - - identity honeycomb-writer-factory { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.write.WriterFactory; - } - - identity honeycomb-writer-registry { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.write.registry.ModifiableWriterRegistryBuilder; - } - - identity honeycomb-writer-registry-builder { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.write.registry.WriterRegistryBuilder; - } - - identity honeycomb-mapping-context { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.MappingContext; - } - -} \ No newline at end of file diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModule.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModule.java deleted file mode 100644 index 99feb57f9..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModule.java +++ /dev/null @@ -1,25 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; - -import io.fd.honeycomb.translate.util.read.registry.CompositeReaderRegistryBuilder; - -public class DelegatingReaderRegistryModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractDelegatingReaderRegistryModule { - public DelegatingReaderRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public DelegatingReaderRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.DelegatingReaderRegistryModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - final CompositeReaderRegistryBuilder flatReaderRegistryBuilder = new CompositeReaderRegistryBuilder(); - getReaderFactoryDependency().forEach(readerFactory -> readerFactory.init(flatReaderRegistryBuilder)); - return flatReaderRegistryBuilder; - } -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModuleFactory.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModuleFactory.java deleted file mode 100644 index 24d6c50b8..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingReaderRegistryModuleFactory.java +++ /dev/null @@ -1,20 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: translate-utils yang module local name: delegating-reader-registry -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Apr 06 12:32:43 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; - -import org.opendaylight.controller.config.api.DynamicMBeanWithInstance; - -public class DelegatingReaderRegistryModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractDelegatingReaderRegistryModuleFactory { - - @Override - public DelegatingReaderRegistryModule handleChangedClass(final DynamicMBeanWithInstance old) throws Exception { - return super.handleChangedClass(old); - } -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModule.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModule.java deleted file mode 100644 index 5ce89b355..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModule.java +++ /dev/null @@ -1,26 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; - -import io.fd.honeycomb.translate.util.write.registry.FlatWriterRegistryBuilder; - -public class DelegatingWriterRegistryModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractDelegatingWriterRegistryModule { - public DelegatingWriterRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public DelegatingWriterRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.DelegatingWriterRegistryModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - final FlatWriterRegistryBuilder flatWriterRegistryBuilder = new FlatWriterRegistryBuilder(); - getWriterFactoryDependency().forEach(writerFactory -> writerFactory.init(flatWriterRegistryBuilder)); - return flatWriterRegistryBuilder; - } - -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModuleFactory.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModuleFactory.java deleted file mode 100644 index ab3b820d3..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/DelegatingWriterRegistryModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: translate-utils yang module local name: delegating-writer-registry -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Apr 06 16:32:08 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; -public class DelegatingWriterRegistryModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractDelegatingWriterRegistryModuleFactory { - -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModule.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModule.java deleted file mode 100644 index be6bb9270..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModule.java +++ /dev/null @@ -1,38 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; - -import io.fd.honeycomb.translate.util.write.NoopWriterRegistry; -import io.fd.honeycomb.translate.write.registry.WriterRegistry; -import io.fd.honeycomb.translate.write.registry.WriterRegistryBuilder; - -public class NoopWriterRegistryModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractNoopWriterRegistryModule { - public NoopWriterRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public NoopWriterRegistryModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.NoopWriterRegistryModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new NoopWriterRegistryBuilder(); - } - - private static final class NoopWriterRegistryBuilder implements AutoCloseable, WriterRegistryBuilder { - - @Override - public WriterRegistry build() { - return new NoopWriterRegistry(); - } - - @Override - public void close() throws Exception { - // Noop - } - } -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModuleFactory.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModuleFactory.java deleted file mode 100644 index 57b6859f3..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/NoopWriterRegistryModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: translate-utils yang module local name: noop-writer-registry -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Tue Apr 12 08:41:08 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; -public class NoopWriterRegistryModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractNoopWriterRegistryModuleFactory { - -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModule.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModule.java deleted file mode 100644 index f882b9ba4..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModule.java +++ /dev/null @@ -1,23 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; - -public class RealtimeMappingContextModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractRealtimeMappingContextModule { - public RealtimeMappingContextModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public RealtimeMappingContextModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.RealtimeMappingContextModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - // Provides real time CRUD on top of Context data broker - return new io.fd.honeycomb.translate.util.RealtimeMappingContext(getContextBindingBrokerDependency()); - } - -} diff --git a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModuleFactory.java b/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModuleFactory.java deleted file mode 100644 index 76647eace..000000000 --- a/infra/translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/translate/utils/rev160406/RealtimeMappingContextModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: translate-utils yang module local name: realtime-mapping-context -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Jun 03 16:04:29 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406; -public class RealtimeMappingContextModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.translate.utils.rev160406.AbstractRealtimeMappingContextModuleFactory { - -} diff --git a/infra/translate-utils/src/main/yang/translate-utils.yang b/infra/translate-utils/src/main/yang/translate-utils.yang deleted file mode 100644 index b543bba0d..000000000 --- a/infra/translate-utils/src/main/yang/translate-utils.yang +++ /dev/null @@ -1,95 +0,0 @@ -module translate-utils { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:translate:utils"; - prefix "tutils"; - - import config { prefix config; revision-date 2013-04-05; } - import translate-api { prefix tapi; revision-date 2016-04-06; } - import opendaylight-md-sal-binding { prefix md-sal-binding; revision-date 2013-10-28;} - - description - "This module contains translation layer utilities"; - - revision "2016-04-06" { - description - "Initial revision."; - } - - identity delegating-reader-registry { - base config:module-type; - config:provided-service tapi:honeycomb-reader-registry; - config:provided-service tapi:honeycomb-reader-registry-builder; - config:java-name-prefix DelegatingReaderRegistry; - } - - augment "/config:modules/config:module/config:configuration" { - case delegating-reader-registry { - when "/config:modules/config:module/config:type = 'delegating-reader-registry'"; - - list reader-factory { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity tapi:honeycomb-reader-factory; - } - } - } - - } - } - - identity delegating-writer-registry { - base config:module-type; - config:provided-service tapi:honeycomb-writer-registry; - config:provided-service tapi:honeycomb-writer-registry-builder; - config:java-name-prefix DelegatingWriterRegistry; - } - - augment "/config:modules/config:module/config:configuration" { - case delegating-writer-registry { - when "/config:modules/config:module/config:type = 'delegating-writer-registry'"; - - list writer-factory { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity tapi:honeycomb-writer-factory; - } - } - } - - } - } - - identity noop-writer-registry-builder { - base config:module-type; - config:provided-service tapi:honeycomb-writer-registry-builder; - config:java-name-prefix NoopWriterRegistry; - } - - augment "/config:modules/config:module/config:configuration" { - case noop-writer-registry-builder { - when "/config:modules/config:module/config:type = 'noop-writer-registry-builder'"; - } - } - - identity realtime-mapping-context { - base config:module-type; - config:provided-service tapi:honeycomb-mapping-context; - } - - augment "/config:modules/config:module/config:configuration" { - case realtime-mapping-context { - when "/config:modules/config:module/config:type = 'realtime-mapping-context'"; - - container context-binding-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - } - } -} \ No newline at end of file diff --git a/packaging/rpm/persist/config/data.json b/packaging/rpm/persist/config/data.json deleted file mode 100644 index e69de29bb..000000000 diff --git a/packaging/rpm/persist/context/data.json b/packaging/rpm/persist/context/data.json deleted file mode 100644 index e69de29bb..000000000 diff --git a/v3po/features/pom.xml b/v3po/features/pom.xml deleted file mode 100644 index 8ffdb10e4..000000000 --- a/v3po/features/pom.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - - io.fd.honeycomb.common - features-parent - 1.0.0-SNAPSHOT - ../../common/features-parent - - io.fd.honeycomb.v3po - v3po-features - 1.0.0-SNAPSHOT - ${project.artifactId} - 4.0.0 - - 3.1.1 - - - 0.8.2-Beryllium-SR2 - 1.3.2-Beryllium-SR2 - 1.3.2-Beryllium-SR2 - 1.0.2-Beryllium-SR2 - 0.8.2-Beryllium-SR2 - 0.3.2-Beryllium-SR2 - etc/opendaylight/karaf - - - - io.fd.honeycomb - honeycomb-features - features - ${project.version} - xml - runtime - - - io.fd.honeycomb.vpp - vpp-common-features - features - ${project.version} - xml - runtime - - - ${project.groupId} - v3po-api - ${project.version} - - - ${project.groupId} - v3po2vpp - ${project.version} - - - ${project.groupId} - v3po2vpp - ${project.version} - xml - config - - - diff --git a/v3po/features/src/main/features/features.xml b/v3po/features/src/main/features/features.xml deleted file mode 100644 index 9ef25aac9..000000000 --- a/v3po/features/src/main/features/features.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - - mvn:io.fd.honeycomb/honeycomb-features/${project.version}/xml/features - mvn:io.fd.honeycomb.vpp/vpp-common-features/${project.version}/xml/features - mvn:org.opendaylight.mdsal.model/features-mdsal-model/${mdsal.model.version}/xml/features - - - odl-mdsal-models - mvn:io.fd.honeycomb.v3po/v3po-api/{{VERSION}} - - - - honeycomb - honeycomb-vpp-common - honeycomb-v3po-api - mvn:io.fd.honeycomb.v3po/v3po2vpp/{{VERSION}} - mvn:io.fd.honeycomb.v3po/v3po2vpp/{{VERSION}}/xml/config - - - - honeycomb-rest - honeycomb-v3po - - - diff --git a/v3po/pom.xml b/v3po/pom.xml index 16bc3902a..edfae2490 100644 --- a/v3po/pom.xml +++ b/v3po/pom.xml @@ -34,8 +34,6 @@ api v3po2vpp - - diff --git a/v3po/v3po2vpp/src/main/config/default-config.xml b/v3po/v3po2vpp/src/main/config/default-config.xml deleted file mode 100644 index e17d7295c..000000000 --- a/v3po/v3po2vpp/src/main/config/default-config.xml +++ /dev/null @@ -1,346 +0,0 @@ - - - - - - - - urn:honeycomb:params:xml:ns:yang:vpp:jvpp:cfg?module=vpp-jvpp-cfg&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:v3po2vpp?module=v3po2vpp&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:data:api?module=data-api&revision=2016-04-11 - urn:honeycomb:params:xml:ns:yang:vpp:util?module=vpp-util&revision=2016-04-06 - - urn:opendaylight:params:xml:ns:yang:controller:threadpool:impl:scheduled?module=threadpool-impl-scheduled&revision=2013-12-01 - - urn:honeycomb:params:xml:ns:yang:notification:impl?module=notification-impl&revision=2016-06-01 - - - - - - - prefix:naming-context-impl - interface-context - interface- - - - prefix:naming-context-impl - bridge-domain-context - bridge-domain- - - - prefix:naming-context-impl - classify-table-context - classify-table- - - - - prefix:vpp-state-honeycomb-reader - vpp-state-honeycomb-reader - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - interface-context - - - prefix:naming-context - bridge-domain-context - - - - - prefix:threadpool - - global-netconf-ssh-scheduled-executor - - - - - - prefix:vpp-interface-notification-producer - vpp-interface-notification-producer - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - interface-context - - - prefix:honeycomb-mapping-context - realtime-mapping-context - - - - - prefix:honeycomb-notification-manager - honeycomb-notification-manager - - prefix:honeycomb-notification-producer - vpp-interface-notification-producer - - - - - - prefix:interfaces-state-honeycomb-reader - interfaces-state-honeycomb-reader - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - interface-context - - - prefix:naming-context - bridge-domain-context - - - prefix:naming-context - classify-table-context - - - - prefix:vpp-classifier-state-honeycomb-reader - vpp-classifier-state-honeycomb-reader - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - classify-table-context - - - - - prefix:vpp-honeycomb-writer - vpp-honeycomb-writer - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - interface-context - - - prefix:naming-context - bridge-domain-context - - - - - prefix:interfaces-honeycomb-writer - interfaces-honeycomb-writer - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - interface-context - - - prefix:naming-context - bridge-domain-context - - - prefix:naming-context - classify-table-context - - - - - prefix:vpp-classifier-honeycomb-writer - vpp-classifier-honeycomb-writer - - prefix:vpp-jvpp - vpp-jvpp - - - prefix:naming-context - classify-table-context - - - - - prefix:delegating-reader-registry - read-registry - - prefix:honeycomb-reader-factory - vpp-state-honeycomb-reader - - - prefix:honeycomb-reader-factory - interfaces-state-honeycomb-reader - - - prefix:honeycomb-reader-factory - vpp-classifier-state-honeycomb-reader - - - - - prefix:delegating-writer-registry - write-registry - - prefix:honeycomb-writer-factory - vpp-honeycomb-writer - - - prefix:honeycomb-writer-factory - interfaces-honeycomb-writer - - - prefix:honeycomb-writer-factory - vpp-classifier-honeycomb-writer - - - - - - prefix:vpp-cfg-initializer - vpp-cfg-initializer - - prefix:binding-async-data-broker - cfg-init-binding-data-broker - - - - - prefix:interfaces-cfg-initializer - interfaces-cfg-initializer - - prefix:binding-async-data-broker - cfg-init-binding-data-broker - - - - - prefix:vpp-classifier-cfg-initializer - vpp-classifier-cfg-initializer - - prefix:binding-async-data-broker - cfg-init-binding-data-broker - - - - - prefix:cfg-initializer-registry - initializer-registry - - prefix:cfg-initializer - vpp-cfg-initializer - - - prefix:cfg-initializer - interfaces-cfg-initializer - - - prefix:cfg-initializer - vpp-classifier-cfg-initializer - - - - - - - prefix:honeycomb-reader-factory - - vpp-state-honeycomb-reader - /modules/module[type='vpp-state-honeycomb-reader'][name='vpp-state-honeycomb-reader'] - - - - interfaces-state-honeycomb-reader - /modules/module[type='interfaces-state-honeycomb-reader'][name='interfaces-state-honeycomb-reader'] - - - vpp-classifier-state-honeycomb-reader - /modules/module[type='vpp-classifier-state-honeycomb-reader'][name='vpp-classifier-state-honeycomb-reader'] - - - - prefix:honeycomb-notification-producer - - vpp-interface-notification-producer - /modules/module[type='vpp-interface-notification-producer'][name='vpp-interface-notification-producer'] - - - - prefix:naming-context - - interface-context - /modules/module[type='naming-context-impl'][name='interface-context'] - - - bridge-domain-context - /modules/module[type='naming-context-impl'][name='bridge-domain-context'] - - - classify-table-context - /modules/module[type='naming-context-impl'][name='classify-table-context'] - - - - prefix:honeycomb-writer-factory - - vpp-honeycomb-writer - /modules/module[type='vpp-honeycomb-writer'][name='vpp-honeycomb-writer'] - - - - interfaces-honeycomb-writer - /modules/module[type='interfaces-honeycomb-writer'][name='interfaces-honeycomb-writer'] - - - - vpp-classifier-honeycomb-writer - /modules/module[type='vpp-classifier-honeycomb-writer'][name='vpp-classifier-honeycomb-writer'] - - - - - - prefix:cfg-initializer - - vpp-cfg-initializer - /modules/module[type='vpp-cfg-initializer'][name='vpp-cfg-initializer'] - - - - interfaces-cfg-initializer - /modules/module[type='interfaces-cfg-initializer'][name='interfaces-cfg-initializer'] - - - - vpp-classifier-cfg-initializer - /modules/module[type='vpp-classifier-cfg-initializer'][name='vpp-classifier-cfg-initializer'] - - - - - - - diff --git a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/Readme.adoc b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/Readme.adoc new file mode 100644 index 000000000..57800d22c --- /dev/null +++ b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/Readme.adoc @@ -0,0 +1,70 @@ += V3po2vpp +V3po2vpp contains v3po-api's handlers (writer/reader) registration into HC infrastructure + +== Writers +Current order of v3po-api writers is: + +. BridgeDomain +. VhostUser +. VxlanGpe +. Tap +. Vxlan +. Interface +. L2 +. SubInterface +. L2 +. Ethernet +. Routing +. ClassifyTable +. ClassifySession +. Acl +. Ipv6 +. Ipv4 +. Address +. Neighbor +. L2FibEntry +. Rewrite +. Address +. Acl + +To find out current order in runtime, turn on logging for writer registry: + + log:set TRACE io.fd.honeycomb.v3po.translate.util.write.registry + +== Readers +There is not a strict order for readers, but current configuration produces approx. this order: + +Contexts +. VppState +. Version +. BridgeDomains +. BridgeDomain +. L2FibTable +. L2FibEntry +. InterfacesState +. Interface +. VppInterfaceStateAugmentation +. Ethernet +. Tap +. VhostUser +. Vxlan +. VxlanGpe +. L2 +. Acl +. Interface2 +. Ipv4 +. Address +. Neighbor +. Ipv6 +. SubinterfaceStateAugmentation +. SubInterfaces +. SubInterface +. L2 +. Rewrite +. Ipv4 +. Address +. Acl +. VppClassifierState +. ClassifyTable +. ClassifySession +. NetconfState \ No newline at end of file diff --git a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/VppClassifierHoneycombWriterFactory.java b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/VppClassifierHoneycombWriterFactory.java index 7c63076d5..98cb32ee8 100644 --- a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/VppClassifierHoneycombWriterFactory.java +++ b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/VppClassifierHoneycombWriterFactory.java @@ -36,9 +36,10 @@ import org.openvpp.jvpp.future.FutureJVpp; public final class VppClassifierHoneycombWriterFactory implements WriterFactory, AutoCloseable { public static final InstanceIdentifier CLASSIFY_TABLE_ID = - InstanceIdentifier.create(VppClassifier.class).child(ClassifyTable.class); + InstanceIdentifier.create(VppClassifier.class).child(ClassifyTable.class); + public static final InstanceIdentifier CLASSIFY_SESSION_ID = - CLASSIFY_TABLE_ID.child(ClassifySession.class); + CLASSIFY_TABLE_ID.child(ClassifySession.class); private final FutureJVpp jvpp; private final NamingContext classifyTableContext; @@ -59,8 +60,7 @@ public final class VppClassifierHoneycombWriterFactory implements WriterFactory, CLASSIFY_SESSION_ID); // ClassifyTableSession registry.addBefore( - new GenericListWriter<>( - CLASSIFY_SESSION_ID, new ClassifySessionWriter(jvpp, classifyTableContext)), + new GenericListWriter<>(CLASSIFY_SESSION_ID, new ClassifySessionWriter(jvpp, classifyTableContext)), ACL_ID); } } diff --git a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/cfgattrs/V3poConfiguration.java b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/cfgattrs/V3poConfiguration.java index afe486c46..9cf5b4d5d 100644 --- a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/cfgattrs/V3poConfiguration.java +++ b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/translate/v3po/cfgattrs/V3poConfiguration.java @@ -17,12 +17,8 @@ package io.fd.honeycomb.translate.v3po.cfgattrs; import net.jmob.guice.conf.core.BindConfig; -import net.jmob.guice.conf.core.InjectConfig; import net.jmob.guice.conf.core.Syntax; @BindConfig(value = "v3po", syntax = Syntax.JSON) public class V3poConfiguration { - - @InjectConfig("some") - String some; } diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModule.java deleted file mode 100644 index 606e27832..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModule.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.initializers.InterfacesInitializer; - -public class InterfacesConfigurationInitializerModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractInterfacesConfigurationInitializerModule { - public InterfacesConfigurationInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public InterfacesConfigurationInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.InterfacesConfigurationInitializerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new InterfacesInitializer(getBindingDataBrokerDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModuleFactory.java deleted file mode 100644 index 726ab0689..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesConfigurationInitializerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: interfaces-cfg-initializer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Thu May 19 14:51:38 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class InterfacesConfigurationInitializerModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractInterfacesConfigurationInitializerModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModule.java deleted file mode 100644 index e63392018..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModule.java +++ /dev/null @@ -1,36 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.InterfacesWriterFactory; - -public class InterfacesHoneycombWriterModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractInterfacesHoneycombWriterModule { - - // TODO split configuration and translation code into 2 or more bundles - - public InterfacesHoneycombWriterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public InterfacesHoneycombWriterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.InterfacesHoneycombWriterModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new InterfacesWriterFactory(getVppJvppIfcDependency(), - getBridgeDomainContextDependency(), - getInterfaceContextDependency(), - getClassifyTableContextDependency()); - } - - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModuleFactory.java deleted file mode 100644 index 9332d3017..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesHoneycombWriterModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: interfaces-honeycomb-writer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Apr 08 13:28:05 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class InterfacesHoneycombWriterModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractInterfacesHoneycombWriterModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModule.java deleted file mode 100644 index 300f44159..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModule.java +++ /dev/null @@ -1,33 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.InterfacesStateReaderFactory; - -public class InterfacesStateHoneycombReaderModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractInterfacesStateHoneycombReaderModule { - - public InterfacesStateHoneycombReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public InterfacesStateHoneycombReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.InterfacesStateHoneycombReaderModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new InterfacesStateReaderFactory(getVppJvppDependency(), - getInterfaceContextIfcStateDependency(), - getBridgeDomainContextIfcStateDependency(), - getClassifyTableContextDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModuleFactory.java deleted file mode 100644 index f1c89f6ef..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/InterfacesStateHoneycombReaderModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: interfaces-state-honeycomb-reader -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Apr 08 10:39:04 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class InterfacesStateHoneycombReaderModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractInterfacesStateHoneycombReaderModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/Readme.adoc b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/Readme.adoc deleted file mode 100644 index 57800d22c..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/Readme.adoc +++ /dev/null @@ -1,70 +0,0 @@ -= V3po2vpp -V3po2vpp contains v3po-api's handlers (writer/reader) registration into HC infrastructure - -== Writers -Current order of v3po-api writers is: - -. BridgeDomain -. VhostUser -. VxlanGpe -. Tap -. Vxlan -. Interface -. L2 -. SubInterface -. L2 -. Ethernet -. Routing -. ClassifyTable -. ClassifySession -. Acl -. Ipv6 -. Ipv4 -. Address -. Neighbor -. L2FibEntry -. Rewrite -. Address -. Acl - -To find out current order in runtime, turn on logging for writer registry: - - log:set TRACE io.fd.honeycomb.v3po.translate.util.write.registry - -== Readers -There is not a strict order for readers, but current configuration produces approx. this order: - -Contexts -. VppState -. Version -. BridgeDomains -. BridgeDomain -. L2FibTable -. L2FibEntry -. InterfacesState -. Interface -. VppInterfaceStateAugmentation -. Ethernet -. Tap -. VhostUser -. Vxlan -. VxlanGpe -. L2 -. Acl -. Interface2 -. Ipv4 -. Address -. Neighbor -. Ipv6 -. SubinterfaceStateAugmentation -. SubInterfaces -. SubInterface -. L2 -. Rewrite -. Ipv4 -. Address -. Acl -. VppClassifierState -. ClassifyTable -. ClassifySession -. NetconfState \ No newline at end of file diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModule.java deleted file mode 100644 index f83e54644..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModule.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.initializers.VppClasifierInitializer; - -public class VppClassifierConfigurationInitializerModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppClassifierConfigurationInitializerModule { - public VppClassifierConfigurationInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppClassifierConfigurationInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppClassifierConfigurationInitializerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new VppClasifierInitializer(getBindingDataBrokerDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModuleFactory.java deleted file mode 100644 index 4e0e7c79e..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierConfigurationInitializerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-classifier-cfg-initializer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Thu Jul 14 16:02:24 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppClassifierConfigurationInitializerModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppClassifierConfigurationInitializerModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModule.java deleted file mode 100644 index 172646c06..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModule.java +++ /dev/null @@ -1,33 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.VppClassifierHoneycombWriterFactory; - -public class VppClassifierHoneycombWriterModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppClassifierHoneycombWriterModule { - - - public VppClassifierHoneycombWriterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppClassifierHoneycombWriterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppClassifierHoneycombWriterModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new VppClassifierHoneycombWriterFactory( - getVppJvppDependency(), - getClassifyTableContextDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModuleFactory.java deleted file mode 100644 index c4ff69061..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierHoneycombWriterModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-classifier-honeycomb-writer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Jun 03 14:05:48 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppClassifierHoneycombWriterModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppClassifierHoneycombWriterModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModule.java deleted file mode 100644 index 4169b784a..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModule.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.VppClassifierReaderFactory; - -public class VppClassifierStateHoneycombReaderModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppClassifierStateHoneycombReaderModule { - public VppClassifierStateHoneycombReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppClassifierStateHoneycombReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppClassifierStateHoneycombReaderModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new VppClassifierReaderFactory(getVppJvppDependency(), getClassifyTableContextDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModuleFactory.java deleted file mode 100644 index 2c1696214..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppClassifierStateHoneycombReaderModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-classifier-state-honeycomb-reader -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Tue Jul 19 13:04:20 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppClassifierStateHoneycombReaderModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppClassifierStateHoneycombReaderModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModule.java deleted file mode 100644 index 266fc408c..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModule.java +++ /dev/null @@ -1,24 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.initializers.VppInitializer; - -public class VppConfigurationInitializerModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppConfigurationInitializerModule { - public VppConfigurationInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppConfigurationInitializerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppConfigurationInitializerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new VppInitializer(getBindingDataBrokerDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModuleFactory.java deleted file mode 100644 index 9ef01e843..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppConfigurationInitializerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-cfg-initializer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Thu May 19 14:51:38 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppConfigurationInitializerModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppConfigurationInitializerModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModule.java deleted file mode 100644 index 63a8a1b67..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModule.java +++ /dev/null @@ -1,32 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.VppHoneycombWriterFactory; - -public class VppHoneycombWriterModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppHoneycombWriterModule { - public VppHoneycombWriterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppHoneycombWriterModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppHoneycombWriterModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new VppHoneycombWriterFactory( - getVppJvppWriterDependency(), - getBridgeDomainContextVppDependency(), - getInterfaceContextVppDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModuleFactory.java deleted file mode 100644 index c350286b8..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppHoneycombWriterModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-honeycomb-writer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Apr 06 11:40:09 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppHoneycombWriterModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppHoneycombWriterModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModule.java deleted file mode 100644 index bb31760ad..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModule.java +++ /dev/null @@ -1,28 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.notification.InterfaceChangeNotificationProducer; - -public class VppInterfaceNotificationProducerModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppInterfaceNotificationProducerModule { - - public VppInterfaceNotificationProducerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppInterfaceNotificationProducerModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppInterfaceNotificationProducerModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new InterfaceChangeNotificationProducer( - getVppJvppDependency(), - getInterfaceContextDependency(), - getRealtimeMappingContextDependency()); - } - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModuleFactory.java deleted file mode 100644 index c80a0d364..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppInterfaceNotificationProducerModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-interface-notification-producer -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Jun 01 17:12:36 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppInterfaceNotificationProducerModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppInterfaceNotificationProducerModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModule.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModule.java deleted file mode 100644 index df216c05a..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModule.java +++ /dev/null @@ -1,99 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; - -import io.fd.honeycomb.translate.v3po.VppStateHoneycombReaderFactory; -import java.lang.management.ManagementFactory; -import javax.management.Attribute; -import javax.management.InstanceNotFoundException; -import javax.management.ObjectName; -import org.opendaylight.controller.config.api.ConflictingVersionException; -import org.opendaylight.controller.config.api.ValidationException; -import org.opendaylight.controller.config.util.ConfigRegistryJMXClient; -import org.opendaylight.controller.config.util.ConfigTransactionJMXClient; -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406.VppJvppImplModule; -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406.VppJvppImplModuleFactory; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class VppStateHoneycombReaderModule extends - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppStateHoneycombReaderModule { - - private static final Logger LOG = LoggerFactory.getLogger(VppStateHoneycombReaderModule.class); - - public VppStateHoneycombReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppStateHoneycombReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, - org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, - org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.VppStateHoneycombReaderModule oldModule, - java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new VppStateHoneycombReaderFactory(getVppJvppDependency(), - getInterfaceContextVppStateDependency(), - getBridgeDomainContextVppStateDependency(), - getKeepaliveExecutorDependency()); - } - - private static long reinitializationCounter; - private static final long reinitializationLimit = 10; - - /** - * In case we detect connection issues with VPP, reinitialize JVpp. - */ - private static void reinitializeJVpp(final long currentAttempt) { - // FIXME https://jira.fd.io/browse/HONEYCOMB-78 This code correctly re-initializes all the components - // starting with jvpp, but jvpp reconnect fails. Test in a JVpp test and then from C - LOG.info("Reinitializing JVpp, attempt: {}", currentAttempt); - - final long nextAttempt = currentAttempt + 1; - if (nextAttempt - reinitializationCounter > reinitializationLimit) { - LOG.error("Too many JVpp reinitialization attempts. Unable to reinitialize JVpp in {} attempts. Giving up", - reinitializationLimit); - throw new IllegalStateException("Too many JVpp reinitialization attempts. Unable to reinitialize JVpp in " - + reinitializationLimit + " attempts. Giving up"); - } - - final ConfigRegistryJMXClient cfgRegistryClient = - ConfigRegistryJMXClient.createWithoutNotifications(ManagementFactory.getPlatformMBeanServer()); - - final ObjectName objectName = cfgRegistryClient.beginConfig(); - final ConfigTransactionJMXClient txClient = cfgRegistryClient.getConfigTransactionClient(objectName); - - final ObjectName jvppOn; - try { - final String attributeName = VppJvppImplModule.descriptionJmxAttribute.getAttributeName(); - final String factoryName = VppJvppImplModuleFactory.NAME; - jvppOn = txClient.lookupConfigBean(factoryName, "vpp-jvpp"); - - // Change configuration attribute of JVpp to trigger full reinitialization here using config subsystem - // TODO improve this when switching from karaf in planned minimal distribution - txClient.setAttribute(jvppOn, attributeName, new Attribute(attributeName, - Long.toString(nextAttempt))); - - txClient.validateConfig(); - cfgRegistryClient.commitConfig(txClient.getObjectName()); - LOG.info("JVpp reinitialized successfully"); - } catch (InstanceNotFoundException | ValidationException e) { - LOG.error("Unable to reinitialize JVpp. Honeycomb will not work properly from now on.", e); - throw new IllegalStateException("Unable to find jvpp instance in config subsystem. Unable to reinitialize JVpp", e); - } catch (ConflictingVersionException e) { - LOG.debug("Conflict changes occurred, retrying", e); - // Just retry until there's no conflicting change in progress - reinitializeJVpp(nextAttempt); - } - - reinitializationCounter = nextAttempt; - } - - -} diff --git a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModuleFactory.java b/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModuleFactory.java deleted file mode 100644 index e9e1c948b..000000000 --- a/v3po/v3po2vpp/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/v3po2vpp/rev160406/VppStateHoneycombReaderModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: v3po2vpp yang module local name: vpp-state-honeycomb-reader -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Wed Apr 06 11:40:09 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406; -public class VppStateHoneycombReaderModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.v3po2vpp.rev160406.AbstractVppStateHoneycombReaderModuleFactory { - -} diff --git a/v3po/v3po2vpp/src/main/resources/honeycomb-minimal-resources/config/v3po.json b/v3po/v3po2vpp/src/main/resources/honeycomb-minimal-resources/config/v3po.json index 290d631f0..7a73a41bf 100644 --- a/v3po/v3po2vpp/src/main/resources/honeycomb-minimal-resources/config/v3po.json +++ b/v3po/v3po2vpp/src/main/resources/honeycomb-minimal-resources/config/v3po.json @@ -1,3 +1,2 @@ { - "some": "value" } \ No newline at end of file diff --git a/v3po/v3po2vpp/src/main/yang/v3po2vpp.yang b/v3po/v3po2vpp/src/main/yang/v3po2vpp.yang deleted file mode 100644 index 1e821f5c1..000000000 --- a/v3po/v3po2vpp/src/main/yang/v3po2vpp.yang +++ /dev/null @@ -1,367 +0,0 @@ -module v3po2vpp { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:v3po2vpp"; - prefix "v3po2vpp"; - - import config { prefix config; revision-date 2013-04-05; } - import translate-api { prefix tapi; revision-date 2016-04-06; } - import vpp-jvpp-cfg { prefix vjvppc; revision-date 2016-04-06; } - import cfg-init { prefix init; revision-date "2016-04-07"; } - import opendaylight-md-sal-binding { prefix md-sal-binding; revision-date 2013-10-28;} - import vpp-util { prefix vpp-u; revision-date 2016-04-06; } - import threadpool {prefix th;} - import notification-api { prefix hc-notif-a; revision-date 2016-06-01; } - - description - "This module contains reads and writers for v3po yang model"; - - revision "2016-04-06" { - description - "Initial revision."; - } - - identity vpp-state-honeycomb-reader { - base config:module-type; - config:provided-service tapi:honeycomb-reader-factory; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-state-honeycomb-reader { - when "/config:modules/config:module/config:type = 'vpp-state-honeycomb-reader'"; - - container vpp-jvpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container interface-context-vpp-state { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container bridge-domain-context-vpp-state { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container keepalive-executor { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity th:scheduled-threadpool; - } - } - - description "Used to schedule keepalives"; - } - } - } - - identity vpp-interface-notification-producer { - base config:module-type; - config:provided-service hc-notif-a:honeycomb-notification-producer; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-interface-notification-producer { - when "/config:modules/config:module/config:type = 'vpp-interface-notification-producer'"; - - container vpp-jvpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container interface-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container realtime-mapping-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity tapi:honeycomb-mapping-context; - } - } - } - } - } - - identity interfaces-state-honeycomb-reader { - base config:module-type; - config:provided-service tapi:honeycomb-reader-factory; - } - - augment "/config:modules/config:module/config:configuration" { - case interfaces-state-honeycomb-reader { - when "/config:modules/config:module/config:type = 'interfaces-state-honeycomb-reader'"; - - container vpp-jvpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container interface-context-ifc-state { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container bridge-domain-context-ifc-state { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container classify-table-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - } - } - - identity vpp-classifier-state-honeycomb-reader { - base config:module-type; - config:provided-service tapi:honeycomb-reader-factory; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-classifier-state-honeycomb-reader { - when "/config:modules/config:module/config:type = 'vpp-classifier-state-honeycomb-reader'"; - - container vpp-jvpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container classify-table-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - } - } - - - identity vpp-honeycomb-writer { - base config:module-type; - config:provided-service tapi:honeycomb-writer-factory; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-honeycomb-writer { - when "/config:modules/config:module/config:type = 'vpp-honeycomb-writer'"; - - container vpp-jvpp-writer { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container interface-context-vpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container bridge-domain-context-vpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - } - } - - identity interfaces-honeycomb-writer { - base config:module-type; - config:provided-service tapi:honeycomb-writer-factory; - } - - augment "/config:modules/config:module/config:configuration" { - case interfaces-honeycomb-writer { - when "/config:modules/config:module/config:type = 'interfaces-honeycomb-writer'"; - - container vpp-jvpp-ifc { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container interface-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container bridge-domain-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - container classify-table-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - - } - } - - identity vpp-classifier-honeycomb-writer { - base config:module-type; - config:provided-service tapi:honeycomb-writer-factory; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-classifier-honeycomb-writer { - when "/config:modules/config:module/config:type = 'vpp-classifier-honeycomb-writer'"; - - container vpp-jvpp { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vjvppc:vpp-jvpp; - } - } - } - - container classify-table-context { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity vpp-u:naming-context; - } - } - } - } - } - - identity vpp-cfg-initializer { - base config:module-type; - config:provided-service init:cfg-initializer; - config:java-name-prefix VppConfigurationInitializer; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-cfg-initializer { - when "/config:modules/config:module/config:type = 'vpp-cfg-initializer'"; - - container binding-data-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - } - } - - identity interfaces-cfg-initializer { - base config:module-type; - config:provided-service init:cfg-initializer; - config:java-name-prefix InterfacesConfigurationInitializer; - } - - augment "/config:modules/config:module/config:configuration" { - case interfaces-cfg-initializer { - when "/config:modules/config:module/config:type = 'interfaces-cfg-initializer'"; - - container binding-data-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - } - } - - identity vpp-classifier-cfg-initializer { - base config:module-type; - config:provided-service init:cfg-initializer; - config:java-name-prefix VppClassifierConfigurationInitializer; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-classifier-cfg-initializer { - when "/config:modules/config:module/config:type = 'vpp-classifier-cfg-initializer'"; - - container binding-data-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - } - } - - -} \ No newline at end of file diff --git a/vpp-common/features/pom.xml b/vpp-common/features/pom.xml deleted file mode 100644 index e0ad56d56..000000000 --- a/vpp-common/features/pom.xml +++ /dev/null @@ -1,89 +0,0 @@ - - - - - io.fd.honeycomb.common - features-parent - 1.0.0-SNAPSHOT - ../../common/features-parent - - io.fd.honeycomb.vpp - vpp-common-features - 1.0.0-SNAPSHOT - ${project.artifactId} - 4.0.0 - - 3.1.1 - - - 0.8.2-Beryllium-SR2 - 1.3.2-Beryllium-SR2 - 1.3.2-Beryllium-SR2 - 1.0.2-Beryllium-SR2 - 0.8.2-Beryllium-SR2 - 0.3.2-Beryllium-SR2 - etc/opendaylight/karaf - - - - io.fd.honeycomb - honeycomb-features - features - ${project.version} - xml - runtime - - - ${project.groupId} - naming-context-api - ${project.version} - - - ${project.groupId} - naming-context-impl - ${project.version} - - - ${project.groupId} - naming-context-impl - ${project.version} - xml - config - - - ${project.groupId} - vpp-jvpp-cfg - ${project.version} - - - ${project.groupId} - vpp-translate-utils - ${project.version} - - - ${project.groupId} - vpp-jvpp-cfg - ${project.version} - xml - config - - - io.fd.vpp - jvpp - 16.09-SNAPSHOT - - - diff --git a/vpp-common/features/src/main/features/features.xml b/vpp-common/features/src/main/features/features.xml deleted file mode 100644 index 321f96e1c..000000000 --- a/vpp-common/features/src/main/features/features.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - mvn:io.fd.honeycomb/honeycomb-features/${project.version}/xml/features - - - honeycomb - mvn:io.fd.honeycomb.vpp/naming-context-api/{{VERSION}} - mvn:io.fd.honeycomb.vpp/naming-context-impl/{{VERSION}} - wrap:mvn:io.fd.vpp/jvpp/{{VERSION}} - mvn:io.fd.honeycomb.vpp/vpp-jvpp-cfg/{{VERSION}} - mvn:io.fd.honeycomb.vpp/vpp-translate-utils/{{VERSION}} - mvn:io.fd.honeycomb.vpp/vpp-jvpp-cfg/{{VERSION}}/xml/config - mvn:io.fd.honeycomb.vpp/naming-context-impl/{{VERSION}}/xml/config - - - diff --git a/vpp-common/minimal-distribution/src/main/java/io/fd/honeycomb/vpp/distro/ContextsReaderFactoryProvider.groovy b/vpp-common/minimal-distribution/src/main/java/io/fd/honeycomb/vpp/distro/ContextsReaderFactoryProvider.groovy index fe71caddb..5016d4e19 100644 --- a/vpp-common/minimal-distribution/src/main/java/io/fd/honeycomb/vpp/distro/ContextsReaderFactoryProvider.groovy +++ b/vpp-common/minimal-distribution/src/main/java/io/fd/honeycomb/vpp/distro/ContextsReaderFactoryProvider.groovy @@ -23,7 +23,7 @@ import groovy.util.logging.Slf4j import io.fd.honeycomb.infra.distro.ProviderTrait import io.fd.honeycomb.translate.read.ReaderFactory import org.opendaylight.controller.md.sal.binding.api.DataBroker -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210.ContextReaderModule +import io.fd.honeycomb.vpp.context.ContextsReaderFactory /** * Mirror of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210.ContextReaderModule @@ -36,5 +36,5 @@ class ContextsReaderFactoryProvider extends ProviderTrait { @Named("honeycomb-context") DataBroker contextDataBroker - def create() { new ContextReaderModule.ContextsReaderFactory(contextDataBroker) } + def create() { new ContextsReaderFactory(contextDataBroker) } } diff --git a/vpp-common/naming-context-impl/src/main/config/default-config.xml b/vpp-common/naming-context-impl/src/main/config/default-config.xml deleted file mode 100644 index 585375844..000000000 --- a/vpp-common/naming-context-impl/src/main/config/default-config.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - urn:opendaylight:params:xml:ns:yang:context:impl?module=context-impl&revision=2014-12-10 - urn:honeycomb:params:xml:ns:yang:translate:utils?module=translate-utils&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:vpp:jvpp:cfg?module=vpp-jvpp-cfg&revision=2016-04-06 - urn:honeycomb:params:xml:ns:yang:data:api?module=data-api&revision=2016-04-11 - urn:honeycomb:params:xml:ns:yang:data:impl?module=data-impl&revision=2016-04-11 - urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&revision=2013-10-28 - - - - - - - - prefix:context-reader - context-reader - - binding:binding-async-data-broker - honeycomb-context-binding-data-broker - - - - prefix:delegating-reader-registry - read-registry - - prefix:honeycomb-reader-factory - context-reader - - - - - - - - prefix:honeycomb-reader-factory - - context-reader - /modules/module[type='context-reader'][name='context-reader'] - - - - - - - diff --git a/vpp-common/naming-context-impl/src/main/java/io/fd/honeycomb/vpp/context/ContextsReaderFactory.java b/vpp-common/naming-context-impl/src/main/java/io/fd/honeycomb/vpp/context/ContextsReaderFactory.java new file mode 100644 index 000000000..6d3a3f13b --- /dev/null +++ b/vpp-common/naming-context-impl/src/main/java/io/fd/honeycomb/vpp/context/ContextsReaderFactory.java @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2016 Cisco and/or its affiliates. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package io.fd.honeycomb.vpp.context; + +import io.fd.honeycomb.translate.read.registry.ModifiableReaderRegistryBuilder; +import io.fd.honeycomb.translate.util.read.BindingBrokerReader; +import org.opendaylight.controller.md.sal.binding.api.DataBroker; +import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; +import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.naming.context.rev160513.Contexts; +import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.naming.context.rev160513.ContextsBuilder; +import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; + +/** + * {@link io.fd.honeycomb.translate.read.ReaderFactory} initiating reader providing data from context data store. + * Making them available over RESTCONF/NETCONF. + */ +public final class ContextsReaderFactory implements AutoCloseable, io.fd.honeycomb.translate.read.ReaderFactory { + + private final DataBroker contextBindingBrokerDependency; + + public ContextsReaderFactory(final DataBroker contextBindingBrokerDependency) { + this.contextBindingBrokerDependency = contextBindingBrokerDependency; + } + + @Override + public void init(final ModifiableReaderRegistryBuilder registry) { + registry.add(new BindingBrokerReader<>(InstanceIdentifier.create(Contexts.class), + contextBindingBrokerDependency, + LogicalDatastoreType.OPERATIONAL, ContextsBuilder.class)); + } +} diff --git a/vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModule.java b/vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModule.java deleted file mode 100644 index ccc01e0ad..000000000 --- a/vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModule.java +++ /dev/null @@ -1,49 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210; - -import io.fd.honeycomb.translate.read.registry.ModifiableReaderRegistryBuilder; -import io.fd.honeycomb.translate.util.read.BindingBrokerReader; -import org.opendaylight.controller.md.sal.binding.api.DataBroker; -import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.naming.context.rev160513.Contexts; -import org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.naming.context.rev160513.ContextsBuilder; -import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; - -/** -* A reader to provide naming context related data -*/ -public class ContextReaderModule extends org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210.AbstractContextReaderModule { - public ContextReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public ContextReaderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210.ContextReaderModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new ContextsReaderFactory(getContextBindingBrokerDependency()); - } - - public static final class ContextsReaderFactory implements AutoCloseable, io.fd.honeycomb.translate.read.ReaderFactory { - - private final DataBroker contextBindingBrokerDependency; - - public ContextsReaderFactory(final DataBroker contextBindingBrokerDependency) { - this.contextBindingBrokerDependency = contextBindingBrokerDependency; - } - - @Override - public void init(final ModifiableReaderRegistryBuilder registry) { - registry.add(new BindingBrokerReader<>(InstanceIdentifier.create(Contexts.class), - contextBindingBrokerDependency, - LogicalDatastoreType.OPERATIONAL, ContextsBuilder.class)); - } - } - -} diff --git a/vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModuleFactory.java b/vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModuleFactory.java deleted file mode 100644 index aaafbc3e3..000000000 --- a/vpp-common/naming-context-impl/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/context/impl/rev141210/ContextReaderModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: context-impl yang module local name: context-reader -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Jul 29 11:05:42 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210; -public class ContextReaderModuleFactory extends org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.context.impl.rev141210.AbstractContextReaderModuleFactory { - -} diff --git a/vpp-common/naming-context-impl/src/main/yang/context-impl.yang b/vpp-common/naming-context-impl/src/main/yang/context-impl.yang deleted file mode 100644 index 12861be68..000000000 --- a/vpp-common/naming-context-impl/src/main/yang/context-impl.yang +++ /dev/null @@ -1,39 +0,0 @@ -module context-impl { - yang-version 1; - namespace "urn:opendaylight:params:xml:ns:yang:context:impl"; - prefix "v3po-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 translate-api { prefix tapi; revision-date 2016-04-06; } - - description - "Service definition for v3po project"; - - revision "2014-12-10" { - description - "Initial revision"; - } - - identity context-reader { - base config:module-type; - config:provided-service tapi:honeycomb-reader-factory; - description "A reader to provide naming context related data"; - } - - augment "/config:modules/config:module/config:configuration" { - case context-reader { - when "/config:modules/config:module/config:type = 'context-reader'"; - - container context-binding-broker { - uses config:service-ref { - refine type { - mandatory true; - config:required-identity md-sal-binding:binding-async-data-broker; - } - } - } - - } - } -} diff --git a/vpp-common/pom.xml b/vpp-common/pom.xml index 42a5221e3..4bcdd6c25 100644 --- a/vpp-common/pom.xml +++ b/vpp-common/pom.xml @@ -33,11 +33,9 @@ vpp-translate-utils - vpp-jvpp-cfg naming-context-api naming-context-impl minimal-distribution - diff --git a/vpp-common/vpp-jvpp-cfg/pom.xml b/vpp-common/vpp-jvpp-cfg/pom.xml deleted file mode 100644 index 79956ef62..000000000 --- a/vpp-common/vpp-jvpp-cfg/pom.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - io.fd.honeycomb.common - impl-parent - 1.0.0-SNAPSHOT - ../../common/impl-parent - - - 4.0.0 - io.fd.honeycomb.vpp - vpp-jvpp-cfg - 1.0.0-SNAPSHOT - bundle - - - - io.fd.vpp - jvpp - 16.09-SNAPSHOT - - - - diff --git a/vpp-common/vpp-jvpp-cfg/src/main/config/default-config.xml b/vpp-common/vpp-jvpp-cfg/src/main/config/default-config.xml deleted file mode 100644 index cbb614e69..000000000 --- a/vpp-common/vpp-jvpp-cfg/src/main/config/default-config.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - - urn:honeycomb:params:xml:ns:yang:vpp:jvpp:cfg?module=vpp-jvpp-cfg&revision=2016-04-06 - - - - - - - prefix:vpp-jvpp-impl - vpp-jvpp - - - - - - prefix:vpp-jvpp - - vpp-jvpp - /modules/module[type='vpp-jvpp-impl'][name='vpp-jvpp'] - - - - - - - diff --git a/vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModule.java b/vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModule.java deleted file mode 100644 index 8eb504a03..000000000 --- a/vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModule.java +++ /dev/null @@ -1,45 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406; - -import java.io.IOException; -import org.openvpp.jvpp.JVppImpl; -import org.openvpp.jvpp.VppJNIConnection; -import org.openvpp.jvpp.future.FutureJVppFacade; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class VppJvppImplModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406.AbstractVppJvppImplModule { - - private static final Logger LOG = LoggerFactory.getLogger(VppJvppImplModule.class); - - public VppJvppImplModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public VppJvppImplModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406.VppJvppImplModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - try { - final JVppImpl jVpp = new JVppImpl(new VppJNIConnection(getName())); - LOG.info("JVpp connection opened successfully as: {}", getName()); - return new FutureJVppFacade(jVpp) { - @Override - public void close() throws Exception { - super.close(); - LOG.info("Closing JVpp connection: {}", getName()); - jVpp.close(); - } - }; - } catch (IOException e) { - throw new IllegalStateException("Unable to open VPP management connection", e); - } - } - -} diff --git a/vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModuleFactory.java b/vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModuleFactory.java deleted file mode 100644 index 71151092d..000000000 --- a/vpp-common/vpp-jvpp-cfg/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/jvpp/cfg/rev160406/VppJvppImplModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: vpp-jvpp-cfg yang module local name: vpp-jvpp-impl -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Fri Apr 29 11:20:56 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406; -public class VppJvppImplModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.jvpp.cfg.rev160406.AbstractVppJvppImplModuleFactory { - -} diff --git a/vpp-common/vpp-jvpp-cfg/src/main/yang/vpp-jvpp-cfg.yang b/vpp-common/vpp-jvpp-cfg/src/main/yang/vpp-jvpp-cfg.yang deleted file mode 100644 index 01a0bf339..000000000 --- a/vpp-common/vpp-jvpp-cfg/src/main/yang/vpp-jvpp-cfg.yang +++ /dev/null @@ -1,43 +0,0 @@ -module vpp-jvpp-cfg { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:vpp:jvpp:cfg"; - prefix "vjvppc"; - - import config { prefix config; revision-date 2013-04-05; } - - description - "This module contains the base YANG definitions for - readers/writers plugged into a honeycomb"; - - revision "2016-04-06" { - description - "Initial revision."; - } - - identity vpp-jvpp { - base "config:service-type"; - config:java-class org.openvpp.jvpp.future.FutureJVpp; - } - - identity vpp-jvpp-impl { - base config:module-type; - config:provided-service vpp-jvpp; - } - - augment "/config:modules/config:module/config:configuration" { - case vpp-jvpp-impl { - when "/config:modules/config:module/config:type = 'vpp-jvpp-impl'"; - - leaf name { - type string; - default "v3poODL"; - } - - leaf description { - type string; - description "Artificial leaf just to trigger reinitialization of JVpp from HC"; - } - } - } - -} \ No newline at end of file diff --git a/vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModule.java b/vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModule.java deleted file mode 100644 index bff1a3a49..000000000 --- a/vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModule.java +++ /dev/null @@ -1,26 +0,0 @@ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.util.rev160406; - -import io.fd.honeycomb.translate.v3po.util.NamingContext; - -public class NamingContextImplModule extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.util.rev160406.AbstractNamingContextImplModule { - public NamingContextImplModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) { - super(identifier, dependencyResolver); - } - - public NamingContextImplModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.util.rev160406.NamingContextImplModule oldModule, java.lang.AutoCloseable oldInstance) { - super(identifier, dependencyResolver, oldModule, oldInstance); - } - - @Override - public void customValidation() { - // add custom validation form module attributes here. - } - - @Override - public java.lang.AutoCloseable createInstance() { - return new NamingContext( - getArtificialNamePrefix(), - getIdentifier().getInstanceName()); - } - -} diff --git a/vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModuleFactory.java b/vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModuleFactory.java deleted file mode 100644 index c777dafa1..000000000 --- a/vpp-common/vpp-translate-utils/src/main/java/org/opendaylight/yang/gen/v1/urn/honeycomb/params/xml/ns/yang/vpp/util/rev160406/NamingContextImplModuleFactory.java +++ /dev/null @@ -1,13 +0,0 @@ -/* -* Generated file -* -* Generated from: yang module name: vpp-util yang module local name: naming-context-impl -* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator -* Generated at: Mon May 02 10:57:32 CEST 2016 -* -* Do not modify this file unless it is present under src/main directory -*/ -package org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.util.rev160406; -public class NamingContextImplModuleFactory extends org.opendaylight.yang.gen.v1.urn.honeycomb.params.xml.ns.yang.vpp.util.rev160406.AbstractNamingContextImplModuleFactory { - -} diff --git a/vpp-common/vpp-translate-utils/src/main/yang/vpp-util.yang b/vpp-common/vpp-translate-utils/src/main/yang/vpp-util.yang deleted file mode 100644 index f9d090c03..000000000 --- a/vpp-common/vpp-translate-utils/src/main/yang/vpp-util.yang +++ /dev/null @@ -1,37 +0,0 @@ -module vpp-util { - yang-version 1; - namespace "urn:honeycomb:params:xml:ns:yang:vpp:util"; - prefix "vpp-u"; - - import config { prefix config; revision-date 2013-04-05; } - import data-api { prefix dapi; revision-date 2016-04-11; } - - description - "This module contains utilities for vpp readers/writers"; - - revision "2016-04-06" { - description - "Initial revision."; - } - - identity naming-context { - base "config:service-type"; - config:java-class io.fd.honeycomb.translate.v3po.util.NamingContext; - } - - identity naming-context-impl { - base config:module-type; - config:provided-service naming-context; - } - - augment "/config:modules/config:module/config:configuration" { - case naming-context-impl { - when "/config:modules/config:module/config:type = 'naming-context-impl'"; - - leaf artificial-name-prefix { - type string; - } - } - } - -} \ No newline at end of file diff --git a/vpp-integration/features/pom.xml b/vpp-integration/features/pom.xml deleted file mode 100644 index 9e8930dec..000000000 --- a/vpp-integration/features/pom.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - - io.fd.honeycomb.common - features-parent - 1.0.0-SNAPSHOT - ../../common/features-parent - - io.fd.honeycomb.vpp.integration - vpp-integration-features - 1.0.0-SNAPSHOT - ${project.artifactId} - 4.0.0 - - 3.1.1 - - - - io.fd.honeycomb - honeycomb-features - ${project.version} - features - xml - runtime - - - - io.fd.honeycomb.vpp - vpp-common-features - ${project.version} - features - xml - runtime - - - - io.fd.honeycomb.v3po - v3po-features - ${project.version} - features - xml - runtime - - - diff --git a/vpp-integration/features/src/main/features/features.xml b/vpp-integration/features/src/main/features/features.xml deleted file mode 100644 index 3dcc7c67a..000000000 --- a/vpp-integration/features/src/main/features/features.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - - - - mvn:io.fd.honeycomb/honeycomb-features/${project.version}/xml/features - - mvn:io.fd.honeycomb.vpp/vpp-common-features/${project.version}/xml/features - - mvn:io.fd.honeycomb.v3po/v3po-features/${project.version}/xml/features - - - honeycomb-api - honeycomb-v3po-api - - - - honeycomb-vpp-integration-api - honeycomb - honeycomb-vpp-common - honeycomb-v3po - - - - honeycomb-vpp-integration - honeycomb-rest - honeycomb-v3po - - - diff --git a/vpp-integration/karaf/pom.xml b/vpp-integration/karaf/pom.xml deleted file mode 100644 index 1232e7375..000000000 --- a/vpp-integration/karaf/pom.xml +++ /dev/null @@ -1,92 +0,0 @@ - - - - - io.fd.honeycomb.common - karaf-parent - 1.0.0-SNAPSHOT - ../../common/karaf-parent - - 4.0.0 - io.fd.honeycomb.vpp.integration - vpp-integration-karaf - 1.0.0-SNAPSHOT - ${project.artifactId} - - 3.1.1 - - - honeycomb-vpp-integration-rest - - - - - - org.apache.karaf.features - framework - kar - - - - io.fd.honeycomb - honeycomb-features - ${project.version} - features - xml - runtime - - - - io.fd.honeycomb.vpp - vpp-common-features - ${project.version} - features - xml - runtime - - - - io.fd.honeycomb.v3po - v3po-features - ${project.version} - features - xml - runtime - - - - io.fd.honeycomb.vpp.integration - vpp-integration-features - ${project.version} - features - xml - runtime - - - - - - - org.apache.maven.plugins - maven-deploy-plugin - - true - - - - - diff --git a/vpp-integration/pom.xml b/vpp-integration/pom.xml index e087abd86..741951b38 100644 --- a/vpp-integration/pom.xml +++ b/vpp-integration/pom.xml @@ -31,8 +31,6 @@ 3.1.1 - - minimal-distribution -- cgit 1.2.3-korg