import org.apache.karaf.shell.commands.Command;
import org.apache.karaf.shell.commands.Option;
import org.apache.karaf.shell.console.OsgiCommandSupport;
-import org.opendaylight.netvirt.bgpmanager.BgpConfigurationManager;
+import org.opendaylight.netvirt.bgpmanager.BgpManager;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.Bgp;
import org.opendaylight.yang.gen.v1.urn.ericsson.params.xml.ns.yang.ebgp.rev150901.bgp.Neighbors;
required = false, multiValued = false)
private final String fbit = null;
- private final BgpConfigurationManager bgpConfigurationManager;
+ private final BgpManager bgpManager;
- public Router(BgpConfigurationManager bgpConfigurationManager) {
- this.bgpConfigurationManager = bgpConfigurationManager;
+ public Router(BgpManager bgpManager) {
+ this.bgpManager = bgpManager;
}
private Object usage() {
return null;
}
}
- bgpConfigurationManager.startBgp(asn, rid, stalePath, fb);
+ bgpManager.startBgp(asn, rid, stalePath, fb);
break;
case "del":
// check: nothing to stop?
if (asNum != null || rid != null || spt != null || fbit != null) {
session.getConsole().println("note: option(s) not needed; ignored");
}
- Bgp conf = bgpConfigurationManager.getConfig();
+ Bgp conf = bgpManager.getConfig();
if (conf == null) {
session.getConsole().println("error : no BGP configs present");
break;
+ "before stopping the router instance");
break;
}
- bgpConfigurationManager.stopBgp();
+ bgpManager.stopBgp();
break;
default:
return usage();