use of org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.meta.rev171210.ovs.bridge.ref.info.OvsBridgeRefEntry in project genius by opendaylight.
the class DirectTunnelUtils method deleteOvsBridgeRefEntry.
public void deleteOvsBridgeRefEntry(BigInteger dpnId) {
LOG.debug("Deleting bridge ref entry for dpn: {}", dpnId);
OvsBridgeRefEntryKey bridgeRefEntryKey = new OvsBridgeRefEntryKey(dpnId);
InstanceIdentifier<OvsBridgeRefEntry> bridgeEntryId = getOvsBridgeRefEntryIdentifier(bridgeRefEntryKey);
jobCoordinator.enqueueJob(ENTITY, () -> Collections.singletonList(txRunner.callWithNewWriteOnlyTransactionAndSubmit(tx -> tx.delete(LogicalDatastoreType.OPERATIONAL, bridgeEntryId))));
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.meta.rev171210.ovs.bridge.ref.info.OvsBridgeRefEntry in project genius by opendaylight.
the class DirectTunnelUtils method createOvsBridgeRefEntry.
public void createOvsBridgeRefEntry(BigInteger dpnId, InstanceIdentifier<?> bridgeIid) {
LOG.debug("Creating bridge ref entry for dpn: {} bridge: {}", dpnId, bridgeIid);
OvsBridgeRefEntryKey bridgeRefEntryKey = new OvsBridgeRefEntryKey(dpnId);
InstanceIdentifier<OvsBridgeRefEntry> bridgeEntryId = getOvsBridgeRefEntryIdentifier(bridgeRefEntryKey);
OvsBridgeRefEntryBuilder tunnelDpnBridgeEntryBuilder = new OvsBridgeRefEntryBuilder().setKey(bridgeRefEntryKey).setDpid(dpnId).setOvsBridgeReference(new OvsdbBridgeRef(bridgeIid));
jobCoordinator.enqueueJob(ENTITY, () -> Collections.singletonList(txRunner.callWithNewWriteOnlyTransactionAndSubmit(tx -> tx.put(LogicalDatastoreType.OPERATIONAL, bridgeEntryId, tunnelDpnBridgeEntryBuilder.build(), true))));
}
Aggregations