Commit 4f6e6574 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Tool - load-gen:

- updated default config
- fixed issue with compatible dst endpoint selection
parent bff93fb2
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -160,13 +160,14 @@ class ServiceGenerator:
        # identify compatible destination endpoint types
        src_endpoint_type = self._endpoint_ids_to_types.get((src_device_uuid,src_endpoint_uuid))
        dst_endpoint_type = ENDPOINT_COMPATIBILITY.get(src_endpoint_type)
        dst_endpoint_types = {dst_endpoint_type} if service_type in {SERVICE_TYPE_TAPI} else None

        # identify expluded destination devices
        exclude_device_uuids = {} if service_type in {SERVICE_TYPE_TAPI} else {src_device_uuid}

        # choose feasible destination endpoint
        dst = self._use_device_endpoint(
            service_uuid, endpoint_types={dst_endpoint_type}, exclude_device_uuids=exclude_device_uuids)
            service_uuid, endpoint_types=dst_endpoint_types, exclude_device_uuids=exclude_device_uuids)
        
        # if destination endpoint not found, release source, and terminate current service generation
        if dst is None:
+3 −3
Original line number Diff line number Diff line
@@ -26,9 +26,9 @@ def main():
    parameters = Parameters(
        num_services  = 100,
        service_types = [
            #SERVICE_TYPE_L2NM,
            #SERVICE_TYPE_L3NM,
            SERVICE_TYPE_TAPI,
            SERVICE_TYPE_L2NM,
            SERVICE_TYPE_L3NM,
            #SERVICE_TYPE_TAPI,
        ],
        offered_load  = 50,
        holding_time  = 10,