First round of ClusterMetadata improvements:
Introduced a PartitionId type for identifying partitions
Introduced a admin service for making metadata updates
Update cluster.json format to specify all partitions (including p0) and changed partitionId to be an int.
Change-Id: Ia0617f1ed0ce886680dcee4f5396a4bbdfa225da
diff --git a/core/api/src/main/java/org/onosproject/cluster/ClusterMetadataService.java b/core/api/src/main/java/org/onosproject/cluster/ClusterMetadataService.java
index 25a6df6..948ee46 100644
--- a/core/api/src/main/java/org/onosproject/cluster/ClusterMetadataService.java
+++ b/core/api/src/main/java/org/onosproject/cluster/ClusterMetadataService.java
@@ -15,10 +15,13 @@
*/
package org.onosproject.cluster;
+import org.onosproject.event.ListenerService;
+
/**
- * Service for obtaining metadata information about the cluster.
+ * Service for accessing {@link ClusterMetadata cluster metadata}.
*/
-public interface ClusterMetadataService {
+public interface ClusterMetadataService
+ extends ListenerService<ClusterMetadataEvent, ClusterMetadataEventListener> {
/**
* Returns the current cluster metadata.
@@ -27,13 +30,7 @@
ClusterMetadata getClusterMetadata();
/**
- * Updates the cluster metadata.
- * @param metadata new metadata
- */
- void setClusterMetadata(ClusterMetadata metadata);
-
- /**
- * Returns the local controller node representing this instance.
+ * Returns the {@link ControllerNode controller node} representing this instance.
* @return local controller node
*/
ControllerNode getLocalNode();