tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 1 | package org.onlab.onos.store.cluster.impl; |
| 2 | |
| 3 | import org.onlab.onos.cluster.DefaultControllerNode; |
tom | 8158314 | 2014-09-30 01:40:29 -0700 | [diff] [blame^] | 4 | import org.onlab.onos.cluster.NodeId; |
| 5 | import org.onlab.packet.IpPrefix; |
tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 6 | |
| 7 | /** |
| 8 | * Simple back interface through which connection manager can interact with |
| 9 | * the cluster store. |
| 10 | */ |
| 11 | public interface ClusterNodesDelegate { |
| 12 | |
| 13 | /** |
tom | 8158314 | 2014-09-30 01:40:29 -0700 | [diff] [blame^] | 14 | * Notifies about cluster node coming online. |
tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 15 | * |
tom | 8158314 | 2014-09-30 01:40:29 -0700 | [diff] [blame^] | 16 | * @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 |
tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 20 | */ |
tom | 8158314 | 2014-09-30 01:40:29 -0700 | [diff] [blame^] | 21 | DefaultControllerNode nodeDetected(NodeId nodeId, IpPrefix ip, int tcpPort); |
tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 22 | |
| 23 | /** |
| 24 | * Notifies about cluster node going offline. |
| 25 | * |
tom | 8158314 | 2014-09-30 01:40:29 -0700 | [diff] [blame^] | 26 | * @param nodeId identifier of the cluster node that vanished |
tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 27 | */ |
tom | 8158314 | 2014-09-30 01:40:29 -0700 | [diff] [blame^] | 28 | void nodeVanished(NodeId nodeId); |
tom | 1d416c5 | 2014-09-29 20:55:24 -0700 | [diff] [blame] | 29 | |
| 30 | } |