diff options
author | Michal Cmarada <mcmarada@cisco.com> | 2019-06-04 18:17:48 +0200 |
---|---|---|
committer | Michal Cmarada <mcmarada@cisco.com> | 2019-06-04 18:17:48 +0200 |
commit | 0c8d4b60217c4d2b85476b951d37fdf1465bc05a (patch) | |
tree | bf3258feb4039792991bbbd817bd05af07cde2ea | |
parent | e2746559f42636e667513024c85c9a6a20de0634 (diff) |
remove interface-state from aclModule
Change-Id: I8b962a9337aab99f0e484fbf6f9d7a7f5f093cd7
Signed-off-by: Michal Cmarada <mcmarada@cisco.com>
5 files changed, 13 insertions, 15 deletions
diff --git a/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/AclIIds.java b/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/AclIIds.java index 4ea5ad3b3..d33bbdbae 100644 --- a/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/AclIIds.java +++ b/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/AclIIds.java @@ -47,7 +47,6 @@ import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.access.cont import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.access.control.list.rev181001.acls.attachment.points._interface.acl.AclSets; import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.access.control.list.rev181001.acls.attachment.points._interface.acl.acl.sets.AclSet; import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.Interfaces; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.InterfacesState; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; public class AclIIds { @@ -67,9 +66,9 @@ public class AclIIds { public static final InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.Interface> IFC = InstanceIdentifier.create(Interfaces.class) .child(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.Interface.class); - public static final InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.state.Interface> - IFC_STATE = InstanceIdentifier.create(InterfacesState.class) - .child(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.state.Interface.class); + public static final InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.Interface> + IFC_STATE = InstanceIdentifier.create(Interfaces.class) + .child(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.Interface.class); public static Set<InstanceIdentifier<?>> vppAclChildren(final InstanceIdentifier<Acl> parentId) { diff --git a/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/read/factory/InterfaceAclReaderFactory.java b/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/read/factory/InterfaceAclReaderFactory.java index 61b66730f..ba84a121e 100644 --- a/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/read/factory/InterfaceAclReaderFactory.java +++ b/acl/acl-impl/src/main/java/io/fd/hc2vpp/acl/read/factory/InterfaceAclReaderFactory.java @@ -57,8 +57,7 @@ public class InterfaceAclReaderFactory implements ReaderFactory { registry.addStructuralReader(AclIIds.ACLS_AP, AttachmentPointsBuilder.class); registry.addAfter(new GenericInitListReader<>(AclIIds.ACLS_AP_INT, - new InterfaceAclCustomizer(futureAclFacade, interfaceContext)), - AclIIds.IFC_STATE); + new InterfaceAclCustomizer(futureAclFacade, interfaceContext)), AclIIds.IFC_STATE); registry.addStructuralReader(AclIIds.ACLS_AP_INT_ING, IngressBuilder.class); registry.addStructuralReader(AclIIds.ACLS_AP_INT_EGR, EgressBuilder.class); diff --git a/acl/acl-impl/src/test/java/io/fd/hc2vpp/acl/AclModuleTest.java b/acl/acl-impl/src/test/java/io/fd/hc2vpp/acl/AclModuleTest.java index 68da5aad8..a2a1f09e4 100644 --- a/acl/acl-impl/src/test/java/io/fd/hc2vpp/acl/AclModuleTest.java +++ b/acl/acl-impl/src/test/java/io/fd/hc2vpp/acl/AclModuleTest.java @@ -47,9 +47,9 @@ import org.junit.Before; import org.junit.Test; import org.mockito.Mock; import org.opendaylight.mdsal.binding.api.DataBroker; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.InterfacesState; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.InterfacesStateBuilder; -import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.state.Interface; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.Interfaces; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.InterfacesBuilder; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev180220.interfaces.Interface; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; @@ -82,15 +82,15 @@ public class AclModuleTest { @Before public void setUp() throws Exception { initMocks(this); - // AclModule adds readers under InterfacesState + // AclModule adds readers under Interfaces // because readers for parents need to be present (are part of V3poModule) // add structural readers here (better than maven dependency). Guice.createInjector(binder -> Multibinder.newSetBinder(binder, ReaderFactory.class) .addBinding().toInstance(registry -> { - registry.addStructuralReader(InstanceIdentifier.create(InterfacesState.class), - InterfacesStateBuilder.class); - registry.add(new GenericListReader<>(InstanceIdentifier.create(InterfacesState.class) + registry.addStructuralReader(InstanceIdentifier.create(Interfaces.class), + InterfacesBuilder.class); + registry.add(new GenericListReader<>(InstanceIdentifier.create(Interfaces.class) .child(Interface.class), mock(ListReaderCustomizer.class))); }), new AclModule(MockJVppAclProvider.class), BoundFieldModule.of(this)).injectMembers(this); diff --git a/l3/impl/src/test/java/L3ModulesTest.java b/l3/impl/src/test/java/L3ModulesTest.java index f1e30f115..af12f15d5 100644 --- a/l3/impl/src/test/java/L3ModulesTest.java +++ b/l3/impl/src/test/java/L3ModulesTest.java @@ -70,7 +70,7 @@ public class L3ModulesTest { public void setUp() { initMocks(this); interfaceContext = new NamingContext("iface", "iface-context"); - // InterfaceL3Module adds readers under InterfacesState + // InterfaceL3Module adds readers under Interfaces // because readers for parents need to be present (are part of V3poModule) // add structural readers here (better than maven dependency). Guice.createInjector(binder -> Multibinder.newSetBinder(binder, ReaderFactory.class) diff --git a/nat/nat2vpp/src/test/java/io/fd/hc2vpp/nat/NatModuleTest.java b/nat/nat2vpp/src/test/java/io/fd/hc2vpp/nat/NatModuleTest.java index bd7cc400d..169449afc 100644 --- a/nat/nat2vpp/src/test/java/io/fd/hc2vpp/nat/NatModuleTest.java +++ b/nat/nat2vpp/src/test/java/io/fd/hc2vpp/nat/NatModuleTest.java @@ -86,7 +86,7 @@ public class NatModuleTest { }; initMocks(this); ifcContext = new NamingContext("interface-", "interface-context"); - // Nat Module adds readers under InterfacesState/Interface and since readers for parents that do nothing need to + // Nat Module adds readers under Interfaces/Interface and since readers for parents that do nothing need to // be present, add structural readers (or add V3poModule here, but adding the full Module is not the best solution) Guice.createInjector(binder -> Multibinder.newSetBinder(binder, ReaderFactory.class) .addBinding().toInstance(registry -> { |