diff options
author | Marek Gradzki <mgradzki@cisco.com> | 2016-06-10 12:42:37 +0200 |
---|---|---|
committer | Marek Gradzki <mgradzki@cisco.com> | 2016-06-10 13:07:17 +0200 |
commit | e8ed5f2450d6ca94b255d6ec9f87173bf88d0c29 (patch) | |
tree | 231edb26314573406a8835ef835a40f6db1d18bd | |
parent | 927bd5f4d9d04b46dbec3b081810a92f8b4572f9 (diff) |
Remove reduntant list of interfaces for BD
Interface has BD reference already
Change-Id: I21d71cc79ec22378e11bfb5fe1bc479b26c21639
Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
-rw-r--r-- | v3po/api/src/main/yang/v3po.yang | 16 | ||||
-rw-r--r-- | v3po/v3po2vpp/src/main/java/io/fd/honeycomb/v3po/translate/v3po/vppstate/BridgeDomainCustomizer.java | 26 |
2 files changed, 0 insertions, 42 deletions
diff --git a/v3po/api/src/main/yang/v3po.yang b/v3po/api/src/main/yang/v3po.yang index b1f2e2c56..69ed9446c 100644 --- a/v3po/api/src/main/yang/v3po.yang +++ b/v3po/api/src/main/yang/v3po.yang @@ -442,22 +442,6 @@ module v3po { uses bridge-domain-attributes; - list interface { - key "name"; - - leaf name { - type if:interface-state-ref; - } - - leaf split-horizon-group { - type uint8; - } - - leaf bridged-virtual-interface { - type boolean; - } - } - list l2-fib { key "phys-address"; diff --git a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/v3po/translate/v3po/vppstate/BridgeDomainCustomizer.java b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/v3po/translate/v3po/vppstate/BridgeDomainCustomizer.java index dabd73ed9..86caf6e5f 100644 --- a/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/v3po/translate/v3po/vppstate/BridgeDomainCustomizer.java +++ b/v3po/v3po2vpp/src/main/java/io/fd/honeycomb/v3po/translate/v3po/vppstate/BridgeDomainCustomizer.java @@ -36,9 +36,6 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.BridgeDomain; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.BridgeDomainBuilder; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.BridgeDomainKey; -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.bridge.domain.Interface; -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.bridge.domain.InterfaceBuilder; -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.bridge.domain.InterfaceKey; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.bridge.domain.L2Fib; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.bridge.domain.L2FibBuilder; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.v3po.rev150105.vpp.state.bridge.domains.bridge.domain.L2FibKey; @@ -48,7 +45,6 @@ import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; import org.openvpp.jvpp.dto.BridgeDomainDetails; import org.openvpp.jvpp.dto.BridgeDomainDetailsReplyDump; import org.openvpp.jvpp.dto.BridgeDomainDump; -import org.openvpp.jvpp.dto.BridgeDomainSwIfDetails; import org.openvpp.jvpp.dto.L2FibTableDump; import org.openvpp.jvpp.dto.L2FibTableEntry; import org.openvpp.jvpp.dto.L2FibTableEntryReplyDump; @@ -104,8 +100,6 @@ public final class BridgeDomainCustomizer extends FutureJVppCustomizer builder.setLearn(byteToBoolean(bridgeDomainDetails.learn)); builder.setUnknownUnicastFlood(byteToBoolean(bridgeDomainDetails.uuFlood)); - builder.setInterface(getIfcs(bridgeDomainDetails, reply.bridgeDomainSwIfDetails, context)); - final L2FibTableDump l2FibRequest = new L2FibTableDump(); l2FibRequest.bdId = bdId; try { @@ -166,26 +160,6 @@ public final class BridgeDomainCustomizer extends FutureJVppCustomizer return sb.toString(); } - private List<Interface> getIfcs(final BridgeDomainDetails bridgeDomainDetails, - final List<BridgeDomainSwIfDetails> bridgeDomainSwIfDetails, - final ReadContext context) { - final List<Interface> ifcs = new ArrayList<>(bridgeDomainSwIfDetails.size()); - for (BridgeDomainSwIfDetails anInterface : bridgeDomainSwIfDetails) { - final String interfaceName = interfaceContext.getName(anInterface.swIfIndex, context.getMappingContext()); - if (anInterface.bdId == bridgeDomainDetails.bdId) { - ifcs.add(new InterfaceBuilder() - .setBridgedVirtualInterface(bridgeDomainDetails.bviSwIfIndex == anInterface.swIfIndex) - .setSplitHorizonGroup((short) anInterface.shg) - .setName(interfaceName) - .setKey(new InterfaceKey(interfaceName)) - .build()); - } - - - } - return ifcs; - } - @Nonnull @Override public BridgeDomainBuilder getBuilder(@Nonnull final InstanceIdentifier<BridgeDomain> id) { |