use of org.onosproject.kubevirtnode.codec.KubevirtNodeCodec in project onos by opennetworkinglab.
the class KubevirtNodeCodecRegister method activate.
@Activate
protected void activate() {
codecService.registerCodec(KubevirtNode.class, new KubevirtNodeCodec());
codecService.registerCodec(KubevirtPhyInterface.class, new KubevirtPhyInterfaceCodec());
codecService.registerCodec(KubevirtApiConfig.class, new KubevirtApiConfigCodec());
log.info("Started");
}
use of org.onosproject.kubevirtnode.codec.KubevirtNodeCodec in project onos by opennetworkinglab.
the class KubevirtNodeWebResourceTest method setUpTest.
/**
* Sets up the global values for all the tests.
*/
@Before
public void setUpTest() {
final CodecManager codecService = new CodecManager();
codecService.activate();
codecService.registerCodec(KubevirtNode.class, new KubevirtNodeCodec());
ServiceDirectory testDirectory = new TestServiceDirectory().add(KubevirtNodeAdminService.class, mockKubevirtNodeAdminService).add(CodecService.class, codecService);
setServiceDirectory(testDirectory);
kubevirtNode = DefaultKubevirtNode.builder().hostname("worker-node").type(KubevirtNode.Type.WORKER).dataIp(IpAddress.valueOf("10.134.34.222")).managementIp(IpAddress.valueOf("10.134.231.30")).intgBridge(DeviceId.deviceId("of:00000000000000a1")).tunBridge(DeviceId.deviceId("of:00000000000000a2")).state(KubevirtNodeState.INIT).build();
}
Aggregations