Close device's source resolution on teardown 67/108167/15
authorSangwook Ha <sangwook.ha@verizon.com>
Mon, 2 Oct 2023 20:24:48 +0000 (13:24 -0700)
committerIvan Hrasko <ivan.hrasko@pantheon.tech>
Fri, 10 Nov 2023 11:45:46 +0000 (11:45 +0000)
commite9518fdc4410b5407318d4b3bcc7fa333e296c55
treea5f29873564281625f2427cc37f029e910040bf0
parente6979d94edadf1ccb2e76c71bf39c2f6c1251d33
Close device's source resolution on teardown

Checking the current connection status is not enough to guarantee that
schema setup was completed for the initial session-up event.

To resolve this close ListenableFuture for device schema resolution
when the 'onRemoteSessionDown' method is called.

This prevents unnecessary duplicate notification, creating duplicate
SchemaContext and avoid confusion in the connection state.

JIRA: NETCONF-1173
Change-Id: I7f84da4a9197db52a0c33d2640e0c2543e587d7b
Signed-off-by: Sangwook Ha <sangwook.ha@verizon.com>
Signed-off-by: Peter Suna <peter.suna@pantheon.tech>
Signed-off-by: Ivan Hrasko <ivan.hrasko@pantheon.tech>
plugins/netconf-client-mdsal/src/main/java/org/opendaylight/netconf/client/mdsal/NetconfDevice.java
plugins/netconf-client-mdsal/src/test/java/org/opendaylight/netconf/client/mdsal/NetconfDeviceTest.java