Commit 889cb6e1 authored by Waleed Akbar's avatar Waleed Akbar
Browse files

Remove unused DSCM plugin files and related components

- Deleted the `datastore.py`, `dscm.py`, `path_resolver.py`, and `requirements.txt` files as they are no longer needed.
- Removed the global store instance and device-specific store logic from `routes.py`.
- Commented out and removed unused route handlers for device configuration in `routes.py`.
- Updated test messages in `dscm_messages.py` to maintain consistency.
- Added backward compatibility in L3VPN handlers
parent b0868e72
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -252,7 +252,6 @@ enum DeviceDriverEnum {
  DEVICEDRIVER_RYU = 18;
  DEVICEDRIVER_GNMI_NOKIA_SRLINUX = 19;
  DEVICEDRIVER_OPENROADM = 20;
  DRVICEDRIVER_NETCONF_DSCM = 21;
}

enum DeviceOperationalStatusEnum {
+0 −2
Original line number Diff line number Diff line
@@ -77,8 +77,6 @@ COPY src/context/__init__.py context/__init__.py
COPY src/context/client/. context/client/
COPY src/device/__init__.py device/__init__.py
COPY src/device/client/. device/client/
COPY src/device/service/drivers/netconf_dscm/. device/service/drivers/netconf_dscm/
COPY src/device/service/driver_api/_Driver.py device/service/driver_api/_Driver.py
COPY src/service/__init__.py service/__init__.py
COPY src/service/client/. service/client/
COPY src/slice/__init__.py slice/__init__.py
+17 −8
Original line number Diff line number Diff line
@@ -115,8 +115,10 @@ def process_site_network_access(
) -> None:
    endpoint_uuid = network_access['site-network-access-id']

    if network_access['site-network-access-type'] != 'ietf-l3vpn-svc:multipoint':
    # if network_access['site-network-access-type'] != 'multipoint':
    if 'ietf-l3vpn-svc' in network_access['site-network-access-type']:
        # replace 'ietf-l3vpn-svc:multipoint' with 'multipoint' for backward compatibility
        network_access['site-network-access-type'] = network_access['site-network-access-type'].replace('ietf-l3vpn-svc:', '')
    if network_access['site-network-access-type'] != 'multipoint':
        MSG = 'Site Network Access Type: {:s}'
        raise NotImplementedError(MSG.format(str(network_access['site-network-access-type'])))

@@ -130,8 +132,10 @@ def process_site_network_access(
        raise NotImplementedError(MSG.format(str(network_access['site-network-access-type'])))

    ipv4_allocation = network_access['ip-connection']['ipv4']
    if ipv4_allocation['address-allocation-type'] != 'ietf-l3vpn-svc:static-address':
    # if ipv4_allocation['address-allocation-type'] != 'static-address':
    if 'ietf-l3vpn-svc' in ipv4_allocation['address-allocation-type']:
        # replace 'ietf-l3vpn-svc:static-address' with 'static-address' for backward compatibility
        ipv4_allocation['address-allocation-type'] = ipv4_allocation['address-allocation-type'].replace('ietf-l3vpn-svc:', '')
    if ipv4_allocation['address-allocation-type'] != 'static-address':
        MSG = 'Site Network Access IPv4 Allocation Type: {:s}'
        raise NotImplementedError(MSG.format(str(ipv4_allocation['address-allocation-type'])))
    ipv4_allocation_addresses = ipv4_allocation['addresses']
@@ -173,8 +177,10 @@ def process_site_network_access(
            MSG = 'Site Network Access QoS Class Id: {:s}'
            raise NotImplementedError(MSG.format(str(qos_profile_class['class-id'])))

        if qos_profile_class['direction'] != 'ietf-l3vpn-svc:both':
        # if qos_profile_class['direction'] != 'both':
        if 'ietf-l3vpn-svc' in qos_profile_class['direction']:
            # replace 'ietf-l3vpn-svc:both' with 'both' for backward compatibility
            qos_profile_class['direction'] = qos_profile_class['direction'].replace('ietf-l3vpn-svc:', '')
        if qos_profile_class['direction'] != 'both':
            MSG = 'Site Network Access QoS Class Direction: {:s}'
            raise NotImplementedError(MSG.format(str(qos_profile_class['direction'])))

@@ -192,6 +198,7 @@ def process_site_network_access(
def process_site(site : Dict, errors : List[Dict]) -> None:
    site_id = site['site-id']

    # this change is made for ECOC2025 demo purposes
    if site['management']['type'] != 'ietf-l3vpn-svc:provider-managed':
    # if site['management']['type'] == 'customer-managed':
        MSG = 'Site Management Type: {:s}'
@@ -202,8 +209,10 @@ def process_site(site : Dict, errors : List[Dict]) -> None:
    site_routing_protocols : Dict = site.get('routing-protocols', dict())
    site_routing_protocol : List = site_routing_protocols.get('routing-protocol', list())
    for rt_proto in site_routing_protocol:
        if rt_proto['type'] != 'ietf-l3vpn-svc:static':
        # if rt_proto['type'] != 'static':
        if 'ietf-l3vpn-svc' in rt_proto['type']:
            # replace 'ietf-l3vpn-svc:static' with 'static' for backward compatibility
            rt_proto['type'] = rt_proto['type'].replace('ietf-l3vpn-svc:', '')
        if rt_proto['type'] != 'static':
            MSG = 'Site Routing Protocol Type: {:s}'
            raise NotImplementedError(MSG.format(str(rt_proto['type'])))

+0 −14
Original line number Diff line number Diff line
# Copyright 2022-2025 ETSI SDG TeraFlowSDN (TFS) (https://tfs.etsi.org/)
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
+0 −710

File deleted.

Preview size limit exceeded, changes collapsed.

Loading