LocationService

Package: simu5g.mec.platform.services.LocationService

simple module LocationService

Implements the Location Service API as defined by the ETSI GS MEC 013 specification. It exposes a REST API that allows MEC applications to retrieve location-related information about User Equipment (UE) or a group of UEs. It supports both request-response and subscribe-notification patterns (in the latter case, the MEC application will be notified when a target UE enters a specific circular area.

simu5g.mec.platform.services.LocationService.LocationServiceLocationServicesimple

Inheritance diagram

Parameters

Name

Type

Default value

Description

requestQueueSize

int

0

subscriptionQueueSize

int

0

localAddress

string

“”

Local address; may be left empty (“”)

localPort

int

1000

localPort number to listen on

locationSubscriptionPeriod

double

1s

loadGenerator

bool

false

betaa

double

0

Used only if loadGenerator is true

numBgApps

int

0

Used only if loadGenerator is true

requestServiceTime

double

0.5us

subscriptionServiceTime

double

0.5us

serverThreadClass

string

“simu5g.mec.platform.services.base.SocketManager”

serviceName

string

“LocationService”

serviceVersion

string

“v2”

serviceSerialize

string

“JSON”

transportId

string

“LocAPI”

transportName

string

“LocAPI”

transportType

string

“REST_HTTP”

transportProtocol

string

“HTTP”

catId

string

“”

catName

string

“Location”

catUri

string

“”

catVersion

string

“v2”

scopeOfLocality

string

“MEC_HOST”

consumedLocalOnly

bool

true

binderModule

string

“binder”

Properties

Name

Value

Description

display

i=block/app

Gates

Name

Direction

Size

Description

socketIn

input

socketOut

output

Signals

Name

Type

Unit

Description

loadGeneratorNumBackgroundRequests

responseTime

Statistics

Name

Title

Source

Record

Unit

Interpolation Mode

Description

loadGeneratorNumBackgroundRequests

Load Generator Background Requests Count

mean,vector

responseTime

Response time of foreground requests

mean,vector

Source code

//
// Implements the Location Service API as defined by the ETSI GS MEC 013 specification.
// It exposes a REST API that allows MEC applications to retrieve location-related information
// about User Equipment (UE) or a group of UEs. It supports both request-response and
// subscribe-notification patterns (in the latter case, the MEC application will be notified when
// a target UE enters a specific circular area.
//
simple LocationService like IMecService, IApp
{
    parameters:
        int requestQueueSize = default(0);
        int subscriptionQueueSize = default(0);
        string localAddress = default(""); // Local address; may be left empty ("")
        int localPort = default(1000);     // localPort number to listen on
        double locationSubscriptionPeriod @unit(s) = default(1s);

        bool loadGenerator = default(false);
        double betaa = default(0);  // Used only if loadGenerator is true
        int numBgApps = default(0); // Used only if loadGenerator is true

        double requestServiceTime @unit(s) = default(0.5us);
        double subscriptionServiceTime @unit(s) = default(0.5us);

        string serverThreadClass = default("simu5g.mec.platform.services.base.SocketManager");

        string serviceName = default("LocationService");
        string serviceVersion = default("v2");
        string serviceSerialize = default("JSON");

        string transportId = default("LocAPI");
        string transportName = default("LocAPI");
        string transportType = default("REST_HTTP");
        string transportProtocol = default("HTTP");

        string catId = default("");
        string catName = default("Location");
        string catUri = default("");
        string catVersion = default("v2");

        string scopeOfLocality = default("MEC_HOST");
        bool consumedLocalOnly = default(true);

        string binderModule = default("binder");

        @display("i=block/app");
        @signal[loadGeneratorNumBackgroundRequests];
        @statistic[loadGeneratorNumBackgroundRequests](title="Load Generator Background Requests Count"; record=mean,vector);
        @signal[responseTime];
        @statistic[responseTime](title="Response time of foreground requests"; record=mean,vector);


    gates:
        input socketIn @labels(TcpCommand/up);
        output socketOut @labels(TcpCommand/down);
}

File: src/simu5g/mec/platform/services/LocationService/LocationService.ned