mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-10-22 21:01:00 +02:00
Register FlowId to Kryo
Change-Id: Ic6bff17cff78f8b95350a97e89782e9c6ae8ce7e
This commit is contained in:
parent
bc3f7f7130
commit
2fcfde9f0d
@ -26,6 +26,7 @@ import org.onlab.onos.net.PortNumber;
|
||||
import org.onlab.onos.net.device.DefaultDeviceDescription;
|
||||
import org.onlab.onos.net.device.DefaultPortDescription;
|
||||
import org.onlab.onos.net.flow.DefaultFlowRule;
|
||||
import org.onlab.onos.net.flow.FlowId;
|
||||
import org.onlab.onos.net.host.DefaultHostDescription;
|
||||
import org.onlab.onos.net.host.HostDescription;
|
||||
import org.onlab.onos.net.link.DefaultLinkDescription;
|
||||
@ -86,7 +87,8 @@ public final class KryoNamespaces {
|
||||
HostId.class,
|
||||
HostDescription.class,
|
||||
DefaultHostDescription.class,
|
||||
DefaultFlowRule.class
|
||||
DefaultFlowRule.class,
|
||||
FlowId.class
|
||||
)
|
||||
.register(URI.class, new URISerializer())
|
||||
.register(NodeId.class, new NodeIdSerializer())
|
||||
|
@ -25,6 +25,7 @@ import org.onlab.onos.net.Link;
|
||||
import org.onlab.onos.net.LinkKey;
|
||||
import org.onlab.onos.net.PortNumber;
|
||||
import org.onlab.onos.net.SparseAnnotations;
|
||||
import org.onlab.onos.net.flow.FlowId;
|
||||
import org.onlab.onos.net.provider.ProviderId;
|
||||
import org.onlab.packet.ChassisId;
|
||||
import org.onlab.packet.IpAddress;
|
||||
@ -191,6 +192,11 @@ public class KryoSerializerTest {
|
||||
testSerialized(new HostLocation(CP1, 1234L));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testFlowId() {
|
||||
testSerialized(FlowId.valueOf(0x12345678L));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testAnnotations() {
|
||||
// Annotations does not have equals defined, manually test equality
|
||||
|
Loading…
x
Reference in New Issue
Block a user