Search in sources :

Example 1 with MockDebugCounterService

use of net.floodlightcontroller.debugcounter.MockDebugCounterService in project open-kilda by telstra.

the class BfdFeatureTest method createSwitchWithDescription.

private static IOFSwitch createSwitchWithDescription(SwitchDescription description) {
    OFFactory factory = new OFFactoryVer13();
    DatapathId dpid = DatapathId.of("1");
    OFConnection connection = new OFConnection(dpid, factory, new LocalChannel(), OFAuxId.MAIN, new MockDebugCounterService(), new HashedWheelTimer());
    OFSwitch sw = new OFSwitch(connection, factory, new OFSwitchManager(), dpid);
    sw.setSwitchProperties(description);
    return sw;
}
Also used : OFSwitchManager(net.floodlightcontroller.core.internal.OFSwitchManager) OFConnection(net.floodlightcontroller.core.internal.OFConnection) MockDebugCounterService(net.floodlightcontroller.debugcounter.MockDebugCounterService) OFFactoryVer13(org.projectfloodlight.openflow.protocol.ver13.OFFactoryVer13) LocalChannel(io.netty.channel.local.LocalChannel) OFFactory(org.projectfloodlight.openflow.protocol.OFFactory) DatapathId(org.projectfloodlight.openflow.types.DatapathId) HashedWheelTimer(io.netty.util.HashedWheelTimer) OFSwitch(net.floodlightcontroller.core.internal.OFSwitch) IOFSwitch(net.floodlightcontroller.core.IOFSwitch)

Aggregations

LocalChannel (io.netty.channel.local.LocalChannel)1 HashedWheelTimer (io.netty.util.HashedWheelTimer)1 IOFSwitch (net.floodlightcontroller.core.IOFSwitch)1 OFConnection (net.floodlightcontroller.core.internal.OFConnection)1 OFSwitch (net.floodlightcontroller.core.internal.OFSwitch)1 OFSwitchManager (net.floodlightcontroller.core.internal.OFSwitchManager)1 MockDebugCounterService (net.floodlightcontroller.debugcounter.MockDebugCounterService)1 OFFactory (org.projectfloodlight.openflow.protocol.OFFactory)1 OFFactoryVer13 (org.projectfloodlight.openflow.protocol.ver13.OFFactoryVer13)1 DatapathId (org.projectfloodlight.openflow.types.DatapathId)1