Fix NetconfNodeHandler interactions 20/107020/14
authorRobert Varga <robert.varga@pantheon.tech>
Sat, 5 Aug 2023 23:08:28 +0000 (01:08 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Mon, 7 Aug 2023 08:08:04 +0000 (10:08 +0200)
commit9db827875364d13611ad3b00f24e42ec259417f4
tree27a8b5771ced881b6fa4768ef7b97431db320b0c
parente129dfb7393b4c4cbee911066bc901f3f4b4a0ec
Fix NetconfNodeHandler interactions

There are a couple of failures in interacting with RemoteDeviceHandler
API (which is completely undocumented).

The API design (and interactions in implementations) assume that:
- onDeviceConnected()/onDeviceDisconnected() manage a reconnecting
  process -- i.e. when 'disconnected' it is assumed the device might
  come back again
- onDeviceFailed() is the hard alternative, indicating the node is node
  coming back

This is then picked up and routed through NetconfTopologyDeviceSalFacade
to NetconfDeviceTopologyAdapter, which makes assumptions and propagates
them to the datastore.

JIRA: NETCONF-1097
Change-Id: Ib148a617b52e775261212aa3a809d1ab450d7d13
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
apps/netconf-topology/src/main/java/org/opendaylight/netconf/topology/spi/ConnectGivenUpException.java [new file with mode: 0644]
apps/netconf-topology/src/main/java/org/opendaylight/netconf/topology/spi/NetconfNodeHandler.java
apps/netconf-topology/src/test/java/org/opendaylight/netconf/topology/spi/NetconfNodeHandlerTest.java