mirror of
https://github.com/opennetworkinglab/onos.git
synced 2026-05-05 20:26:16 +02:00
[ONOS-7766] Modify the use of invalidated checkReply methods in Netconf
Change-Id: I4400c33373a93926bcc8a397db4f24e141790b63
This commit is contained in:
parent
3dceff2dba
commit
8b03bc583b
@ -410,7 +410,10 @@ public class NetconfSessionMinaImpl extends AbstractNetconfSession {
|
||||
@Override
|
||||
public String requestSync(String request) throws NetconfException {
|
||||
String reply = sendRequest(request);
|
||||
checkReply(reply);
|
||||
if (!checkReply(reply)) {
|
||||
throw new NetconfException("Request not successful with device "
|
||||
+ deviceInfo + " with reply " + reply);
|
||||
}
|
||||
return reply;
|
||||
}
|
||||
|
||||
@ -494,7 +497,10 @@ public class NetconfSessionMinaImpl extends AbstractNetconfSession {
|
||||
throw new NetconfTransportException(t);
|
||||
} else {
|
||||
// FIXME avoid using checkReply, error handling is weird
|
||||
checkReply(reply);
|
||||
if (!checkReply(reply)) {
|
||||
throw new NetconfTransportException("rpc-request not successful with device "
|
||||
+ deviceInfo + " with reply " + reply);
|
||||
}
|
||||
return reply;
|
||||
}
|
||||
}, SharedExecutors.getPoolThreadExecutor());
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user