Commit fcc6fd44 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

DLT Connector component:

- when updating remote slice locally, remove sub-service and sub-slice identifiers since they relate to internal data in remote domain.
parent 83081fff
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -194,7 +194,15 @@ class DltEventDispatcher(threading.Thread):
            # it is owned by me
            # just update it locally
            LOGGER.info('[_dispatch_slice] updating locally')
            clients.context_client.SetSlice(slice_)

            local_slice = Slice()
            local_slice.CopyFrom(slice_)

            # pylint: disable=no-member
            local_slice.slice_service_ids.Clear()   # they are from remote domains so will not be present locally
            local_slice.slice_subslice_ids.Clear()  # they are from remote domains so will not be present locally

            clients.context_client.SetSlice(local_slice)
        else:
            MSG = '[_dispatch_slice] Ignoring DLT event received (remote): {:s}'
            LOGGER.info(MSG.format(grpc_message_to_json_string(event)))