mirror of
https://github.com/opennetworkinglab/onos.git
synced 2026-05-05 20:26:16 +02:00
Add sdk-port annotation with discover port from Stratum
Change-Id: I37f810767df9fb5adee815cd19e78c71a1aaa37c (cherry picked from commit ca5cfe77821b2a750570a80418be30a90af25d9b)
This commit is contained in:
parent
6d557c0751
commit
e48c599b0b
@ -58,6 +58,7 @@ public class OpenConfigGnmiDeviceDescriptionDiscovery
|
||||
.getLogger(OpenConfigGnmiDeviceDescriptionDiscovery.class);
|
||||
|
||||
private static final String LAST_CHANGE = "last-change";
|
||||
private static final String SDK_PORT = "sdk-port";
|
||||
|
||||
private static final String UNKNOWN = "unknown";
|
||||
|
||||
@ -170,6 +171,7 @@ public class OpenConfigGnmiDeviceDescriptionDiscovery
|
||||
switch (pathElemName) {
|
||||
case "ifindex": // port number
|
||||
builder.withPortNumber(PortNumber.portNumber(val.getUintVal(), ifName));
|
||||
annotationsBuilder.set(SDK_PORT, String.valueOf(val.getUintVal()));
|
||||
return;
|
||||
case "oper-status":
|
||||
builder.isEnabled(parseOperStatus(val.getStringVal()));
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user