blob: 0c47d188b8fd7b3bac2a587c99bca3d0d56726ce [file] [log] [blame]
tom1d416c52014-09-29 20:55:24 -07001package org.onlab.onos.store.cluster.impl;
2
3import org.onlab.onos.cluster.DefaultControllerNode;
tom81583142014-09-30 01:40:29 -07004import org.onlab.onos.cluster.NodeId;
5import org.onlab.packet.IpPrefix;
tom1d416c52014-09-29 20:55:24 -07006
7/**
8 * Simple back interface through which connection manager can interact with
9 * the cluster store.
10 */
11public interface ClusterNodesDelegate {
12
13 /**
tom81583142014-09-30 01:40:29 -070014 * Notifies about cluster node coming online.
tom1d416c52014-09-29 20:55:24 -070015 *
tom81583142014-09-30 01:40:29 -070016 * @param nodeId newly detected cluster node id
17 * @param ip node IP listen address
18 * @param tcpPort node TCP listen port
19 * @return the controller node
tom1d416c52014-09-29 20:55:24 -070020 */
tom81583142014-09-30 01:40:29 -070021 DefaultControllerNode nodeDetected(NodeId nodeId, IpPrefix ip, int tcpPort);
tom1d416c52014-09-29 20:55:24 -070022
23 /**
24 * Notifies about cluster node going offline.
25 *
tom81583142014-09-30 01:40:29 -070026 * @param nodeId identifier of the cluster node that vanished
tom1d416c52014-09-29 20:55:24 -070027 */
tom81583142014-09-30 01:40:29 -070028 void nodeVanished(NodeId nodeId);
tom1d416c52014-09-29 20:55:24 -070029
30}