Add clustered-app-config blueprint extension 90/38390/7
authorTom Pantelis <tpanteli@brocade.com>
Wed, 4 May 2016 02:20:06 +0000 (22:20 -0400)
committerAnil Vishnoi <vishnoianil@gmail.com>
Thu, 12 May 2016 21:23:49 +0000 (21:23 +0000)
commit1ecaae69e61d9eca89b7521d542ca2ec4885c98d
treeb887ee2415a390aa1e9366aea8789c793d9ca247
parent2e7a820b74cc232da3b3ece2ce4991ead7cbab01
Add clustered-app-config blueprint extension

Added an extension that obtains a given binding DataObject type from the data
store and provides the DataObject instance to the Blueprint container as a
bean that can be injected into oher beans. In addition it registers a
ClusteredDataTreeChangeListener to restart the Blueprint container when the
data is changed. If no DataObject instance exists, an instance is created
with any defaults values populated. Default data may be specified via
the "default-config" child element which must contain the XML representation
of the yang data, including namespace, wrapped in a CDATA section to prevent
the blueprint container from treating it as markup.

It is assumed the given "binding-class" is a top-level yang container or
list, which seems reasonable. If it's nested then the full path would
have to be specified via XML which is doable but not worth the added
work if not necessary. We'll see if there's a use case for a nested app
config (I doubt it).

A list agg config would be used if there's multiple instances of the
app/module (eg "openflow-switch-connection-provider-impl" in the
openflowplugin). The "list-key-value" must be specified. It is assumed
there's only one list key and that it's a string, ie the yang list is
keyed by the name of app/module.

Change-Id: Ib970b003526d42c2a3db085036174967f055cbba
Signed-off-by: Tom Pantelis <tpanteli@brocade.com>
opendaylight/blueprint/pom.xml
opendaylight/blueprint/src/main/java/org/opendaylight/controller/blueprint/ext/ComponentProcessor.java
opendaylight/blueprint/src/main/java/org/opendaylight/controller/blueprint/ext/DataStoreAppConfigMetadata.java [new file with mode: 0644]
opendaylight/blueprint/src/main/java/org/opendaylight/controller/blueprint/ext/MandatoryServiceReferenceMetadata.java [new file with mode: 0644]
opendaylight/blueprint/src/main/java/org/opendaylight/controller/blueprint/ext/OpendaylightNamespaceHandler.java
opendaylight/blueprint/src/main/java/org/opendaylight/controller/blueprint/ext/StaticServiceReferenceRecipe.java [new file with mode: 0644]
opendaylight/blueprint/src/main/resources/opendaylight-blueprint-ext-1.0.0.xsd