Code Review
/
vpnservice.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
support to get fib service in vpn manager
[vpnservice.git]
/
vpnmanager
/
vpnmanager-impl
/
src
/
main
/
java
/
org
/
opendaylight
/
vpnservice
/
VpnserviceProvider.java
diff --git
a/vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/vpnservice/VpnserviceProvider.java
b/vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/vpnservice/VpnserviceProvider.java
index 6b462e4e5d975e10698194576f9b470ecc9ea0c2..e4d6e8970bfad95ad640a91c5e5bdfedf7bcdd08 100644
(file)
--- a/
vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/vpnservice/VpnserviceProvider.java
+++ b/
vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/vpnservice/VpnserviceProvider.java
@@
-17,6
+17,7
@@
import org.opendaylight.bgpmanager.api.IBgpManager;
import org.opendaylight.controller.md.sal.binding.api.DataBroker;
import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext;
import org.opendaylight.controller.sal.binding.api.BindingAwareProvider;
import org.opendaylight.controller.md.sal.binding.api.DataBroker;
import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext;
import org.opendaylight.controller.sal.binding.api.BindingAwareProvider;
+import org.opendaylight.fibmanager.api.IFibManager;
import org.opendaylight.vpnmanager.api.IVpnManager;
import org.opendaylight.vpnservice.interfacemgr.interfaces.IInterfaceManager;
import org.opendaylight.vpnservice.mdsalutil.interfaces.IMdsalApiManager;
import org.opendaylight.vpnmanager.api.IVpnManager;
import org.opendaylight.vpnservice.interfacemgr.interfaces.IInterfaceManager;
import org.opendaylight.vpnservice.mdsalutil.interfaces.IMdsalApiManager;
@@
-34,6
+35,7
@@
public class VpnserviceProvider implements BindingAwareProvider, IVpnManager,
private VpnInterfaceManager vpnInterfaceManager;
private VpnManager vpnManager;
private IBgpManager bgpManager;
private VpnInterfaceManager vpnInterfaceManager;
private VpnManager vpnManager;
private IBgpManager bgpManager;
+ private IFibManager fibManager;
private IMdsalApiManager mdsalManager;
private IInterfaceManager interfaceManager;
private IdManagerService idManager;
private IMdsalApiManager mdsalManager;
private IInterfaceManager interfaceManager;
private IdManagerService idManager;
@@
-64,6
+66,10
@@
public class VpnserviceProvider implements BindingAwareProvider, IVpnManager,
this.mdsalManager = mdsalManager;
}
this.mdsalManager = mdsalManager;
}
+ public void setFibManager(IFibManager fibManager) {
+ this.fibManager = fibManager;
+ }
+
public void setInterfaceManager(IInterfaceManager interfaceManager) {
this.interfaceManager = interfaceManager;
}
public void setInterfaceManager(IInterfaceManager interfaceManager) {
this.interfaceManager = interfaceManager;
}
@@
-81,7
+87,7
@@
public class VpnserviceProvider implements BindingAwareProvider, IVpnManager,
try {
Future<RpcResult<Void>> result = idManager.createIdPool(createPool);
if ((result != null) && (result.get().isSuccessful())) {
try {
Future<RpcResult<Void>> result = idManager.createIdPool(createPool);
if ((result != null) && (result.get().isSuccessful())) {
- LOG.
info
("Created IdPool for VPN Service");
+ LOG.
debug
("Created IdPool for VPN Service");
}
} catch (InterruptedException | ExecutionException e) {
LOG.error("Failed to create idPool for VPN Service",e);
}
} catch (InterruptedException | ExecutionException e) {
LOG.error("Failed to create idPool for VPN Service",e);
@@
-98,4
+104,11
@@
public class VpnserviceProvider implements BindingAwareProvider, IVpnManager,
public Collection<Long> getDpnsForVpn(long vpnId) {
return vpnInterfaceManager.getDpnsForVpn(vpnId);
}
public Collection<Long> getDpnsForVpn(long vpnId) {
return vpnInterfaceManager.getDpnsForVpn(vpnId);
}
+
+ @Override
+ public void setFibService(IFibManager fibManager) {
+ LOG.debug("Fib service reference is initialized in VPN Manager");
+ this.fibManager = fibManager;
+ vpnInterfaceManager.setFibManager(fibManager);
+ }
}
}