diff --git a/proto/context.proto b/proto/context.proto index 4d61572df1db6c95b64e9ce1cbfdd9e0db111078..01e096233e364be8ad4e3810e7619e8f522e66e6 100644 --- a/proto/context.proto +++ b/proto/context.proto @@ -223,6 +223,9 @@ enum DeviceDriverEnum { DEVICEDRIVER_IETF_ACTN = 10; DEVICEDRIVER_OC = 11; DEVICEDRIVER_QKD = 12; + DEVICEDRIVER_IETF_L3VPN = 13; + DEVICEDRIVER_IETF_SLICE = 14; + DEVICEDRIVER_NCE = 15; } enum DeviceOperationalStatusEnum { diff --git a/src/common/DeviceTypes.py b/src/common/DeviceTypes.py index eb315352b47bbe501f66868c0181a0d34cd6cfed..30bbd0b15e9d199294a3d7ee7826b22695d0e45c 100644 --- a/src/common/DeviceTypes.py +++ b/src/common/DeviceTypes.py @@ -52,3 +52,6 @@ class DeviceTypeEnum(Enum): # ETSI TeraFlowSDN controller TERAFLOWSDN_CONTROLLER = 'teraflowsdn' + IETF_SLICE = 'ietf-slice' + + NCE = 'nce' \ No newline at end of file diff --git a/src/common/tools/context_queries/Slice.py b/src/common/tools/context_queries/Slice.py index c826c59ce79adbe1e399d674ffd46a421ddd9b5e..41bfb686bd000ac18716e8c06764b309d52c8914 100644 --- a/src/common/tools/context_queries/Slice.py +++ b/src/common/tools/context_queries/Slice.py @@ -12,12 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -import grpc, logging -from typing import Optional +import logging +from typing import Optional, Tuple, Union +from uuid import UUID, uuid5 + +import grpc + from common.Constants import DEFAULT_CONTEXT_NAME -from common.proto.context_pb2 import Slice, SliceFilter, SliceId +from common.method_wrappers.ServiceExceptions import InvalidArgumentsException +from common.proto.context_pb2 import ContextId, Slice, SliceFilter, SliceId from context.client.ContextClient import ContextClient + +NAMESPACE_TFS = UUID("200e3a1f-2223-534f-a100-758e29c37f40") + LOGGER = logging.getLogger(__name__) def get_slice_by_id( @@ -59,3 +67,96 @@ def get_slice_by_uuid( context_client, slice_id, rw_copy=rw_copy, include_endpoint_ids=include_endpoint_ids, include_constraints=include_constraints, include_service_ids=include_service_ids, include_subslice_ids=include_subslice_ids, include_config_rules=include_config_rules) + + +def get_uuid_from_string( + str_uuid_or_name: Union[str, UUID], prefix_for_name: Optional[str] = None +) -> str: + # if UUID given, assume it is already a valid UUID + if isinstance(str_uuid_or_name, UUID): + return str_uuid_or_name + if not isinstance(str_uuid_or_name, str): + MSG = "Parameter({:s}) cannot be used to produce a UUID" + raise Exception(MSG.format(str(repr(str_uuid_or_name)))) + try: + # try to parse as UUID + return str(UUID(str_uuid_or_name)) + except: # pylint: disable=bare-except + # produce a UUID within TFS namespace from parameter + if prefix_for_name is not None: + str_uuid_or_name = "{:s}/{:s}".format(prefix_for_name, str_uuid_or_name) + return str(uuid5(NAMESPACE_TFS, str_uuid_or_name)) + + +def context_get_uuid( + context_id: ContextId, + context_name: str = "", + allow_random: bool = False, + allow_default: bool = False, +) -> str: + context_uuid = context_id.context_uuid.uuid + + if len(context_uuid) > 0: + return get_uuid_from_string(context_uuid) + if len(context_name) > 0: + return get_uuid_from_string(context_name) + if allow_default: + return get_uuid_from_string(DEFAULT_CONTEXT_NAME) + + raise InvalidArgumentsException( + [ + ("context_id.context_uuid.uuid", context_uuid), + ("name", context_name), + ], + extra_details=["At least one is required to produce a Context UUID"], + ) + + +def slice_get_uuid(slice_id: SliceId) -> Tuple[str, str]: + context_uuid = context_get_uuid(slice_id.context_id, allow_random=False) + raw_slice_uuid = slice_id.slice_uuid.uuid + + if len(raw_slice_uuid) > 0: + return context_uuid, get_uuid_from_string( + raw_slice_uuid, prefix_for_name=context_uuid + ) + + raise InvalidArgumentsException( + [ + ("slice_id.slice_uuid.uuid", raw_slice_uuid), + ], + extra_details=["At least one is required to produce a Slice UUID"], + ) + +def get_slice_by_defualt_id( + context_client : ContextClient, default_slice_id : SliceId, context_uuid : str = DEFAULT_CONTEXT_NAME, + rw_copy : bool = False, include_endpoint_ids : bool = True, include_constraints : bool = True, + include_service_ids : bool = True, include_subslice_ids : bool = True, include_config_rules : bool = True +) -> Optional[Slice]: + context_uuid, slice_uuid = slice_get_uuid(default_slice_id) + LOGGER.debug(f'P60: {context_uuid} {slice_uuid}') + slice_id = SliceId() + slice_id.context_id.context_uuid.uuid = context_uuid # pylint: disable=no-member + slice_id.slice_uuid.uuid = slice_uuid # pylint: disable=no-member + return get_slice_by_id( + context_client, slice_id, rw_copy=rw_copy, include_endpoint_ids=include_endpoint_ids, + include_constraints=include_constraints, include_service_ids=include_service_ids, + include_subslice_ids=include_subslice_ids, include_config_rules=include_config_rules) + + +def get_slice_by_defualt_name( + context_client : ContextClient, slice_name : str, context_uuid : str = DEFAULT_CONTEXT_NAME, + rw_copy : bool = False, include_endpoint_ids : bool = True, include_constraints : bool = True, + include_service_ids : bool = True, include_subslice_ids : bool = True, include_config_rules : bool = True +) -> Optional[Slice]: + default_slice_id = SliceId() + default_slice_id.context_id.context_uuid.uuid = context_uuid # pylint: disable=no-member + default_slice_id.slice_uuid.uuid = slice_name # pylint: disable=no-member + context_uuid, slice_uuid = slice_get_uuid(default_slice_id) + slice_id = SliceId() + slice_id.context_id.context_uuid.uuid = context_uuid # pylint: disable=no-member + slice_id.slice_uuid.uuid = slice_uuid # pylint: disable=no-member + return get_slice_by_id( + context_client, slice_id, rw_copy=rw_copy, include_endpoint_ids=include_endpoint_ids, + include_constraints=include_constraints, include_service_ids=include_service_ids, + include_subslice_ids=include_subslice_ids, include_config_rules=include_config_rules) \ No newline at end of file diff --git a/src/common/tools/descriptor/Tools.py b/src/common/tools/descriptor/Tools.py index c8807cef0d1357c732d34b11580d1f73e157501a..2ecd38ae146f5c5e3a04a84ad3bb05385554f659 100644 --- a/src/common/tools/descriptor/Tools.py +++ b/src/common/tools/descriptor/Tools.py @@ -115,6 +115,8 @@ CONTROLLER_DEVICE_TYPES = { DeviceTypeEnum.MICROWAVE_RADIO_SYSTEM.value, DeviceTypeEnum.OPEN_LINE_SYSTEM.value, DeviceTypeEnum.TERAFLOWSDN_CONTROLLER.value, + DeviceTypeEnum.IETF_SLICE.value, + DeviceTypeEnum.NCE.value, } def split_controllers_and_network_devices(devices : List[Dict]) -> Tuple[List[Dict], List[Dict]]: diff --git a/src/common/tools/grpc/ConfigRules.py b/src/common/tools/grpc/ConfigRules.py index c8919273e65c6f6edb0f3e0ca6f060a5471e8f0e..0cf5165e9a15e1bcbaa4067db1e866ab01fbe33c 100644 --- a/src/common/tools/grpc/ConfigRules.py +++ b/src/common/tools/grpc/ConfigRules.py @@ -54,14 +54,13 @@ def update_config_rule_custom( config_rule.custom.resource_value = json.dumps(json_resource_value, sort_keys=True) -def copy_config_rules(source_config_rules, target_config_rules): +def copy_config_rules(source_config_rules, target_config_rules, raise_if_differs = True): for source_config_rule in source_config_rules: config_rule_kind = source_config_rule.WhichOneof('config_rule') if config_rule_kind == 'custom': custom = source_config_rule.custom resource_key = custom.resource_key resource_value = json.loads(custom.resource_value) - raise_if_differs = True fields = {name:(value, raise_if_differs) for name,value in resource_value.items()} update_config_rule_custom(target_config_rules, resource_key, fields) diff --git a/src/context/service/database/models/enums/DeviceDriver.py b/src/context/service/database/models/enums/DeviceDriver.py index 5342f788a7b273aa7f6ae3c5779774165cd852bc..fe0d83fb1886a42526b1c71304b7e3ecc2b0b7d7 100644 --- a/src/context/service/database/models/enums/DeviceDriver.py +++ b/src/context/service/database/models/enums/DeviceDriver.py @@ -33,6 +33,9 @@ class ORM_DeviceDriverEnum(enum.Enum): GNMI_OPENCONFIG = DeviceDriverEnum.DEVICEDRIVER_GNMI_OPENCONFIG OPTICAL_TFS = DeviceDriverEnum.DEVICEDRIVER_OPTICAL_TFS IETF_ACTN = DeviceDriverEnum.DEVICEDRIVER_IETF_ACTN + IETF_L3VPN = DeviceDriverEnum.DEVICEDRIVER_IETF_L3VPN + NCE = DeviceDriverEnum.DEVICEDRIVER_NCE + IETF_SLICE = DeviceDriverEnum.DEVICEDRIVER_IETF_SLICE OC = DeviceDriverEnum.DEVICEDRIVER_OC QKD = DeviceDriverEnum.DEVICEDRIVER_QKD diff --git a/src/device/service/drivers/__init__.py b/src/device/service/drivers/__init__.py index b99ee50ca8319ab96f9062a3c58c356fa2ae7ec7..bfadaafdd7961cc6ce09ee8491503b15e42a7ab8 100644 --- a/src/device/service/drivers/__init__.py +++ b/src/device/service/drivers/__init__.py @@ -90,6 +90,24 @@ DRIVERS.append( } ])) +from .ietf_slice.driver import IetfSliceDriver # pylint: disable=wrong-import-position +DRIVERS.append( + (IetfSliceDriver, [ + { + FilterFieldEnum.DEVICE_TYPE: DeviceTypeEnum.IETF_SLICE, + FilterFieldEnum.DRIVER: DeviceDriverEnum.DEVICEDRIVER_IETF_SLICE, + } + ])) + +from .nce.driver import NCEDriver # pylint: disable=wrong-import-position +DRIVERS.append( + (NCEDriver, [ + { + FilterFieldEnum.DEVICE_TYPE: DeviceTypeEnum.NCE, + FilterFieldEnum.DRIVER: DeviceDriverEnum.DEVICEDRIVER_NCE, + } + ])) + if LOAD_ALL_DEVICE_DRIVERS: from .openconfig.OpenConfigDriver import OpenConfigDriver # pylint: disable=wrong-import-position DRIVERS.append( diff --git a/src/pathcomp/frontend/service/algorithms/tools/ComposeConfigRules.py b/src/pathcomp/frontend/service/algorithms/tools/ComposeConfigRules.py index f0775371d0f3fea01411ce4049226377feebc27e..9eac4d353ef48f6e75b478d137e6e9bb9c3e1c03 100644 --- a/src/pathcomp/frontend/service/algorithms/tools/ComposeConfigRules.py +++ b/src/pathcomp/frontend/service/algorithms/tools/ComposeConfigRules.py @@ -22,6 +22,8 @@ LOGGER = logging.getLogger(__name__) SETTINGS_RULE_NAME = '/settings' STATIC_ROUTING_RULE_NAME = '/static_routing' +RUNNING_RESOURCE_KEY = "running_ietf_slice" +CANDIDATE_RESOURCE_KEY = "candidate_ietf_slice" RE_UUID = re.compile(r'([0-9a-fA-F]{8})\-([0-9a-fA-F]{4})\-([0-9a-fA-F]{4})\-([0-9a-fA-F]{4})\-([0-9a-fA-F]{12})') @@ -93,6 +95,8 @@ def compose_l3nm_config_rules(main_service_config_rules : List, subservice_confi CONFIG_RULES = [ (SETTINGS_RULE_NAME, L3NM_SETTINGS_FIELD_DEFAULTS), (STATIC_ROUTING_RULE_NAME, {}), + (RUNNING_RESOURCE_KEY, {}), + (CANDIDATE_RESOURCE_KEY, {}), ] for rule_name, defaults in CONFIG_RULES: compose_config_rules(main_service_config_rules, subservice_config_rules, rule_name, defaults) diff --git a/src/pathcomp/frontend/service/algorithms/tools/ResourceGroups.py b/src/pathcomp/frontend/service/algorithms/tools/ResourceGroups.py index b08830332f7fc6f526a19516b120e94a1a98b232..db0c552487363e4bb283832c7e40a4e7623e994c 100644 --- a/src/pathcomp/frontend/service/algorithms/tools/ResourceGroups.py +++ b/src/pathcomp/frontend/service/algorithms/tools/ResourceGroups.py @@ -28,6 +28,9 @@ DEVICE_TYPE_TO_DEEPNESS = { DeviceTypeEnum.TERAFLOWSDN_CONTROLLER.value : 80, DeviceTypeEnum.EMULATED_IP_SDN_CONTROLLER.value : 80, DeviceTypeEnum.IP_SDN_CONTROLLER.value : 80, + DeviceTypeEnum.IETF_SLICE.value : 80, + DeviceTypeEnum.NCE.value : 80, + DeviceTypeEnum.EMULATED_PACKET_ROUTER.value : 70, DeviceTypeEnum.PACKET_ROUTER.value : 70, diff --git a/src/pathcomp/frontend/service/algorithms/tools/ServiceTypes.py b/src/pathcomp/frontend/service/algorithms/tools/ServiceTypes.py index 8230092c2decc0b2c988f63a2677f879f7ec944f..ae567d9d65e4d971930fecb0971672f5bdb1ab73 100644 --- a/src/pathcomp/frontend/service/algorithms/tools/ServiceTypes.py +++ b/src/pathcomp/frontend/service/algorithms/tools/ServiceTypes.py @@ -22,6 +22,7 @@ NETWORK_DEVICE_TYPES = { PACKET_DEVICE_TYPES = { DeviceTypeEnum.TERAFLOWSDN_CONTROLLER, + DeviceTypeEnum.IETF_SLICE, DeviceTypeEnum.NCE, DeviceTypeEnum.IP_SDN_CONTROLLER, DeviceTypeEnum.EMULATED_IP_SDN_CONTROLLER, DeviceTypeEnum.PACKET_ROUTER, DeviceTypeEnum.EMULATED_PACKET_ROUTER, DeviceTypeEnum.PACKET_SWITCH, DeviceTypeEnum.EMULATED_PACKET_SWITCH, diff --git a/src/service/requirements.in b/src/service/requirements.in index 3f8d2a35453691420a9469dfffd0a0d2648c6397..d0dd6dcfe13610fc315a50437fb5f3e094b4ee5e 100644 --- a/src/service/requirements.in +++ b/src/service/requirements.in @@ -13,6 +13,7 @@ # limitations under the License. +deepdiff==6.7.* anytree==2.8.0 geopy==2.3.0 netaddr==0.9.0 diff --git a/src/service/service/service_handler_api/FilterFields.py b/src/service/service/service_handler_api/FilterFields.py index 78f084605bcd759825975cb7f11abc659506755b..585bad6b04ceb182587532d517459d508af416d9 100644 --- a/src/service/service/service_handler_api/FilterFields.py +++ b/src/service/service/service_handler_api/FilterFields.py @@ -42,6 +42,9 @@ DEVICE_DRIVER_VALUES = { DeviceDriverEnum.DEVICEDRIVER_GNMI_OPENCONFIG, DeviceDriverEnum.DEVICEDRIVER_OPTICAL_TFS, DeviceDriverEnum.DEVICEDRIVER_IETF_ACTN, + DeviceDriverEnum.DEVICEDRIVER_NCE, + DeviceDriverEnum.DEVICEDRIVER_IETF_SLICE, + DeviceDriverEnum.DEVICEDRIVER_IETF_L3VPN, DeviceDriverEnum.DEVICEDRIVER_OC, DeviceDriverEnum.DEVICEDRIVER_QKD, } diff --git a/src/service/service/service_handlers/__init__.py b/src/service/service/service_handlers/__init__.py index f93cf011fe02139ae350b91eab52eb71ded0574d..3d1ae9041443977985a13ca272bbe7a1b1cc0769 100644 --- a/src/service/service/service_handlers/__init__.py +++ b/src/service/service/service_handlers/__init__.py @@ -21,6 +21,8 @@ from .l3nm_emulated.L3NMEmulatedServiceHandler import L3NMEmulatedServiceHandler from .l3nm_openconfig.L3NMOpenConfigServiceHandler import L3NMOpenConfigServiceHandler from .l3nm_gnmi_openconfig.L3NMGnmiOpenConfigServiceHandler import L3NMGnmiOpenConfigServiceHandler from .l3nm_ietf_actn.L3NMIetfActnServiceHandler import L3NMIetfActnServiceHandler +from .l3nm_nce.L3NMNCEServiceHandler import L3NMNCEServiceHandler +from .l3slice_ietfslice.L3SliceIETFSliceServiceHandler import L3NMSliceIETFSliceServiceHandler from .microwave.MicrowaveServiceHandler import MicrowaveServiceHandler from .p4.p4_service_handler import P4ServiceHandler from .tapi_tapi.TapiServiceHandler import TapiServiceHandler @@ -66,6 +68,18 @@ SERVICE_HANDLERS = [ FilterFieldEnum.DEVICE_DRIVER : DeviceDriverEnum.DEVICEDRIVER_IETF_ACTN, } ]), + (L3NMNCEServiceHandler, [ + { + FilterFieldEnum.SERVICE_TYPE : ServiceTypeEnum.SERVICETYPE_L3NM, + FilterFieldEnum.DEVICE_DRIVER : DeviceDriverEnum.DEVICEDRIVER_NCE, + } + ]), + (L3NMSliceIETFSliceServiceHandler, [ + { + FilterFieldEnum.SERVICE_TYPE : ServiceTypeEnum.SERVICETYPE_L3NM, + FilterFieldEnum.DEVICE_DRIVER : DeviceDriverEnum.DEVICEDRIVER_IETF_SLICE, + } + ]), (TapiServiceHandler, [ { FilterFieldEnum.SERVICE_TYPE : ServiceTypeEnum.SERVICETYPE_TAPI_CONNECTIVITY_SERVICE, diff --git a/src/service/service/service_handlers/l3nm_emulated/ConfigRules.py b/src/service/service/service_handlers/l3nm_emulated/ConfigRules.py index 1d6764619e81864e9b048319a087f1a10f17d601..f1b02eab564c6a2eb38f25e4567a2a04ca0156ed 100644 --- a/src/service/service/service_handlers/l3nm_emulated/ConfigRules.py +++ b/src/service/service/service_handlers/l3nm_emulated/ConfigRules.py @@ -43,7 +43,7 @@ def setup_config_rules( vlan_id = json_endpoint_settings.get('vlan_id', 1 ) # 400 address_ip = json_endpoint_settings.get('address_ip', '0.0.0.0') # '2.2.2.1' address_prefix = json_endpoint_settings.get('address_prefix', 24 ) # 30 - if_subif_name = '{:s}.{:d}'.format(endpoint_name, vlan_id) + if_subif_name = '{:s}.{:s}'.format(endpoint_name, str(vlan_id)) json_config_rules = [ json_config_rule_set( @@ -57,7 +57,7 @@ def setup_config_rules( 'name': endpoint_name, 'description': network_interface_desc, 'mtu': mtu, }), json_config_rule_set( - '/interface[{:s}]/subinterface[{:d}]'.format(endpoint_name, sub_interface_index), { + '/interface[{:s}]/subinterface[{:s}]'.format(endpoint_name, str(sub_interface_index)), { 'name': endpoint_name, 'index': sub_interface_index, 'description': network_subinterface_desc, 'vlan_id': vlan_id, 'address_ip': address_ip, 'address_prefix': address_prefix, @@ -163,7 +163,7 @@ def teardown_config_rules( #address_ip = json_endpoint_settings.get('address_ip', '0.0.0.0') # '2.2.2.1' #address_prefix = json_endpoint_settings.get('address_prefix', 24 ) # 30 - if_subif_name = '{:s}.{:d}'.format(endpoint_name, vlan_id) + if_subif_name = '{:s}.{:s}'.format(endpoint_name, str(vlan_id)) service_short_uuid = service_uuid.split('-')[-1] network_instance_name = '{:s}-NetInst'.format(service_short_uuid) #network_interface_desc = '{:s}-NetIf'.format(service_uuid) @@ -175,7 +175,7 @@ def teardown_config_rules( 'name': network_instance_name, 'id': if_subif_name, }), json_config_rule_delete( - '/interface[{:s}]/subinterface[{:d}]'.format(endpoint_name, sub_interface_index), { + '/interface[{:s}]/subinterface[{:s}]'.format(endpoint_name, str(sub_interface_index)), { 'name': endpoint_name, 'index': sub_interface_index, }), json_config_rule_delete( diff --git a/src/service/service/task_scheduler/TaskExecutor.py b/src/service/service/task_scheduler/TaskExecutor.py index 6fb1eca3497fef311605e2cd202ca74bd9cb730f..51fc42a5a5ea06d5abaa49946a154d0c38f6de8b 100644 --- a/src/service/service/task_scheduler/TaskExecutor.py +++ b/src/service/service/task_scheduler/TaskExecutor.py @@ -287,8 +287,12 @@ class TaskExecutor: devices.setdefault(device_type, dict())[device_uuid] = device else: if not exclude_managed_by_controller: - device_type = DeviceTypeEnum._value2member_map_[device.device_type] - devices.setdefault(device_type, dict())[device_uuid] = device + controller_device_type_enum = DeviceTypeEnum._value2member_map_[controller.device_type] + if controller_device_type_enum == DeviceTypeEnum.IETF_SLICE: + devices.setdefault(controller_device_type_enum, dict())[device_uuid] = device + else: + device_type = DeviceTypeEnum._value2member_map_[device.device_type] + devices.setdefault(device_type, dict())[device_uuid] = device device_type = DeviceTypeEnum._value2member_map_[controller.device_type] devices.setdefault(device_type, dict())[controller.device_id.device_uuid.uuid] = controller return devices @@ -321,7 +325,7 @@ class TaskExecutor: self, connection : Connection, service : Service, **service_handler_settings ) -> Dict[DeviceTypeEnum, Tuple['_ServiceHandler', Dict[str, Device]]]: connection_device_types : Dict[DeviceTypeEnum, Dict[str, Device]] = self.get_devices_from_connection( - connection, exclude_managed_by_controller=True + connection, exclude_managed_by_controller=False ) service_handlers : Dict[DeviceTypeEnum, Tuple['_ServiceHandler', Dict[str, Device]]] = dict() for device_type, connection_devices in connection_device_types.items(): diff --git a/src/slice/service/SliceServiceServicerImpl.py b/src/slice/service/SliceServiceServicerImpl.py index 007d012ed432a6d4ab589f6dfe28648a9a6d2a85..68bd0aef153d2b784605abfe03b891b6990d23d5 100644 --- a/src/slice/service/SliceServiceServicerImpl.py +++ b/src/slice/service/SliceServiceServicerImpl.py @@ -19,7 +19,7 @@ from common.proto.context_pb2 import ( from common.proto.slice_pb2_grpc import SliceServiceServicer from common.method_wrappers.Decorator import MetricsPool, safe_and_metered_rpc_method from common.tools.context_queries.InterDomain import is_inter_domain #, is_multi_domain -from common.tools.context_queries.Slice import get_slice_by_id +from common.tools.context_queries.Slice import get_slice_by_defualt_id, get_slice_by_id from common.tools.grpc.ConfigRules import copy_config_rules from common.tools.grpc.Constraints import copy_constraints from common.tools.grpc.EndPointIds import copy_endpoint_ids @@ -45,6 +45,8 @@ class SliceServiceServicerImpl(SliceServiceServicer): # being modified. context_client = ContextClient() slice_ro : Optional[Slice] = get_slice_by_id(context_client, request.slice_id, rw_copy=False) + if not slice_ro: + slice_ro : Optional[Slice] = get_slice_by_defualt_id(context_client, request.slice_id, rw_copy=False) slice_rw = Slice() slice_rw.CopyFrom(request if slice_ro is None else slice_ro) @@ -52,9 +54,9 @@ class SliceServiceServicerImpl(SliceServiceServicer): slice_rw.slice_owner.CopyFrom(request.slice_owner) # pylint: disable=no-member slice_rw.slice_status.slice_status = SliceStatusEnum.SLICESTATUS_PLANNED # pylint: disable=no-member - copy_endpoint_ids(request.slice_endpoint_ids, slice_rw.slice_endpoint_ids ) # pylint: disable=no-member - copy_constraints (request.slice_constraints, slice_rw.slice_constraints ) # pylint: disable=no-member - copy_config_rules(request.slice_config.config_rules, slice_rw.slice_config.config_rules) # pylint: disable=no-member + copy_endpoint_ids(request.slice_endpoint_ids, slice_rw.slice_endpoint_ids ) # pylint: disable=no-member + copy_constraints (request.slice_constraints, slice_rw.slice_constraints ) # pylint: disable=no-member + copy_config_rules(request.slice_config.config_rules, slice_rw.slice_config.config_rules, False) # pylint: disable=no-member slice_id_with_uuids = context_client.SetSlice(slice_rw) @@ -112,7 +114,7 @@ class SliceServiceServicerImpl(SliceServiceServicer): # pylint: disable=no-member copy_endpoint_ids(request.slice_endpoint_ids, service_request.service_endpoint_ids) copy_constraints(request.slice_constraints, service_request.service_constraints) - copy_config_rules(request.slice_config.config_rules, service_request.service_config.config_rules) + copy_config_rules(request.slice_config.config_rules, service_request.service_config.config_rules, False) service_request.service_type = ServiceTypeEnum.SERVICETYPE_UNKNOWN for config_rule in request.slice_config.config_rules: