X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=networkmodel%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Ftransportpce%2Fnetworkmodel%2Fservice%2FNetworkModelService.java;h=879ed961e4c1a3eac8714000e5467506f2875562;hb=63ac411af040169c3f9908c57aff8d9e8aed2abf;hp=51ee4a190617c8d493dcac2644740269adbf0246;hpb=9f04e99bf6c53ce3218835145085fb75dc5b4590;p=transportpce.git diff --git a/networkmodel/src/main/java/org/opendaylight/transportpce/networkmodel/service/NetworkModelService.java b/networkmodel/src/main/java/org/opendaylight/transportpce/networkmodel/service/NetworkModelService.java index 51ee4a190..879ed961e 100644 --- a/networkmodel/src/main/java/org/opendaylight/transportpce/networkmodel/service/NetworkModelService.java +++ b/networkmodel/src/main/java/org/opendaylight/transportpce/networkmodel/service/NetworkModelService.java @@ -8,8 +8,11 @@ package org.opendaylight.transportpce.networkmodel.service; import java.util.List; -import org.opendaylight.yang.gen.v1.http.transportpce.topology.rev201019.OtnLinkType; +import org.opendaylight.yang.gen.v1.http.org.opendaylight.transportpce.portmapping.rev210927.mapping.Mapping; +import org.opendaylight.yang.gen.v1.http.org.opendaylight.transportpce.renderer.rev210915.renderer.rpc.result.sp.Link; +import org.opendaylight.yang.gen.v1.http.transportpce.topology.rev210511.OtnLinkType; import org.opendaylight.yang.gen.v1.urn.opendaylight.netconf.node.topology.rev150114.NetconfNodeConnectionStatus; +import org.opendaylight.yangtools.yang.common.Uint32; /** * Service for data manipulation on OpenROADM topology models. @@ -27,13 +30,26 @@ public interface NetworkModelService { void createOpenRoadmNode(String nodeId, String nodeVersion); /** - * Delete OpenROADM node mapping and topologies. + * Delete OpenROADM node from portmapping and topologies. * * @param nodeId * unique node ID of OpenROADM node. * + * @return result of node deletion from portmapping and topologies */ - void deleteOpenRoadmnode(String nodeId); + boolean deleteOpenRoadmnode(String nodeId); + + /** + * Update termination point, and if need, be associated links, of + * openroadm-topology and otn-topology after a change on a given mapping. + * + * @param nodeId + * unique node ID of OpenROADM node at the origin of the NETCONF + * notification change. + * @param mapping + * updated mapping following the device notification change. + */ + void updateOpenRoadmTopologies(String nodeId, Mapping mapping); /** * Set/update connection status of OpenROADM node. @@ -78,21 +94,38 @@ public interface NetworkModelService { void deleteOtnLinks(String nodeA, String tpA, String nodeZ, String tpZ, OtnLinkType linkType); /** - * update otn links from otn-topology. + * Update otn links from otn-topology. + * For services using low-order odu, updates bandwidth parameters + * for both the direct parent high-order odu link, and also its server + * otu link. * - * @param nodeTps - * List containing a string composed of the netconf nodeId , and the - * termination point supporting the service + * @param link + * link containing termination points to be updated * @param serviceRate - * Service rate may be 1G, 10G or 100G + * Service rate may be 1G, 10G, 100G or 400G * @param tribPortNb * Trib port number allocated by the service - * @param tribSoltNb - * First trib slot number allocated by the service + * @param minTribSoltNb + * First contiguous trib slot number allocated by the service + * @param maxTribSoltNb + * Last contiguous trib slot number allocated by the service * @param isDeletion - * True indicates if the low-order otn service must be deleted + * True indicates if the low-order otn service must be deleted */ - void updateOtnLinks(List nodeTps, String serviceRate, Short tribPortNb, Short tribSoltNb, - boolean isDeletion); + void updateOtnLinks(Link link, Uint32 serviceRate, Short tribPortNb, Short minTribSoltNb, Short maxTribSoltNb, + boolean isDeletion); + /** + * Update otn links from otn-topology. + * For services using directly a high-order odu, updates bandwidth parameters + * of the direct parent otu link. + * + * @param link + * link containing termination points to be updated + * @param supportedLinks + * list of link-id supported the service (used when more than one supported link) + * @param isDeletion + * True indicates if the low-order otn service must be deleted + */ + void updateOtnLinks(Link link, List supportedLinks, boolean isDeletion); }