Skip to content
Snippets Groups Projects
Commit 86a23017 authored by Shudong Zhou's avatar Shudong Zhou
Browse files

Log switch description strings

parent 992cb880
No related branches found
No related tags found
No related merge requests found
......@@ -773,13 +773,13 @@ public class Controller implements IFloodlightProviderService,
sw.setSwitchProperties(state.description);
readPropertyFromStorage();
log.info("Switch {} bound to class {}",
HexString.toHexString(sw.getId()), sw.getClass().getName());
log.info("{}", state.description);
state.featuresReply = null;
state.description = null;
state.switchBindingDone = true;
log.info("Switch {} bound to class {}",
HexString.toHexString(sw.getId()), sw.getClass().getName());
return;
}
private void readPropertyFromStorage() {
......
......@@ -296,15 +296,15 @@ public class RoleChanger {
while(iter.hasNext()) {
IOFSwitch sw = iter.next();
try {
int xid = sendHARoleRequest(sw, role, cookie);
PendingRoleRequestEntry entry =
new PendingRoleRequestEntry(xid, role, cookie);
LinkedList<PendingRoleRequestEntry> pendingList
= pendingRequestMap.get(sw);
if (pendingList == null) {
pendingList = new LinkedList<PendingRoleRequestEntry>();
pendingRequestMap.put(sw, pendingList);
}
int xid = sendHARoleRequest(sw, role, cookie);
PendingRoleRequestEntry entry =
new PendingRoleRequestEntry(xid, role, cookie);
// Need to synchronize against removal from list
synchronized(pendingList) {
pendingList.add(entry);
......
......@@ -213,4 +213,13 @@ public class OFDescriptionStatistics implements OFStatistics {
}
return true;
}
@Override
public String toString() {
return "Switch Desc - Vendor: " + manufacturerDescription +
" Model: " + hardwareDescription +
" Make: " + datapathDescription +
" Version: " + softwareDescription +
" S/N: " + serialNumber;
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment