[ONOS-8137] Bug fixed for driver not found in case of ipv6 address being used in short notation
Change-Id: I8fd0922eb2cce98ecb5612979f0554ac2281351b
diff --git a/protocols/netconf/api/src/main/java/org/onosproject/netconf/NetconfDeviceInfo.java b/protocols/netconf/api/src/main/java/org/onosproject/netconf/NetconfDeviceInfo.java
index 3ef4e60..17849fc 100644
--- a/protocols/netconf/api/src/main/java/org/onosproject/netconf/NetconfDeviceInfo.java
+++ b/protocols/netconf/api/src/main/java/org/onosproject/netconf/NetconfDeviceInfo.java
@@ -126,8 +126,9 @@
/**
* Convenieince constructor that converts all known fields from NetCfg data.
* @param netconfConfig NetCf configuration
+ * @param deviceId deviceId as per netcfg
*/
- public NetconfDeviceInfo(NetconfDeviceConfig netconfConfig) {
+ public NetconfDeviceInfo(NetconfDeviceConfig netconfConfig, DeviceId deviceId) {
checkArgument(!netconfConfig.username().isEmpty(), "Empty device name");
checkArgument(netconfConfig.port() > 0, "Negative port");
checkNotNull(netconfConfig.ip(), "Null ip address");
@@ -135,6 +136,7 @@
this.name = netconfConfig.username();
this.password = netconfConfig.password();
this.ipAddress = netconfConfig.ip();
+ this.deviceId = deviceId;
this.port = netconfConfig.port();
this.path = netconfConfig.path();
if (netconfConfig.sshKey() != null && !netconfConfig.sshKey().isEmpty()) {