client

package module
v0.0.0-...-11d08c8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 6, 2020 License: Apache-2.0 Imports: 21 Imported by: 0

README

Go API client for client

This API is the main platform API and mainly used by the AdvantEDGE frontend to interact with scenarios

Micro-service
meep-ctrl-engine

Type & Usage
Platform main interface used by controller software that want to interact with the AdvantEDGE platform

Details
API details available at your-AdvantEDGE-ip-address:30000/api

Default Port
30000

Overview

This API client was generated by the swagger-codegen project. By using the swagger-spec from a remote server, you can easily generate an API client.

  • API version: 1.0.0
  • Package version: 1.0.0
  • Build package: io.swagger.codegen.languages.GoClientCodegen

Installation

Put the package under your project folder and add the following in import:

import "./client"

Documentation for API Endpoints

All URIs are relative to http://localhost/v1

Class Method HTTP request Description
EventReplayApi CreateReplayFile Post /replay/{name} Add a replay file
EventReplayApi CreateReplayFileFromScenarioExec Post /replay/{name}/generate Generate a replay file from scenario execution events
EventReplayApi DeleteReplayFile Delete /replay/{name} Delete a replay file
EventReplayApi DeleteReplayFileList Delete /replay Delete all replay files
EventReplayApi GetReplayFile Get /replay/{name} Get a specific replay file
EventReplayApi GetReplayFileList Get /replay Get all replay file names
EventReplayApi GetReplayStatus Get /replaystatus Get status of replay manager
EventReplayApi LoopReplay Post /replay/{name}/loop Loop-Execute a replay file present in the platform store
EventReplayApi PlayReplayFile Post /replay/{name}/play Execute a replay file present in the platform store
EventReplayApi StopReplayFile Post /replay/{name}/stop Stop execution of a replay file
PodStatesApi GetStates Get /states Get pods states
ScenarioConfigurationApi CreateScenario Post /scenarios/{name} Add a scenario
ScenarioConfigurationApi DeleteScenario Delete /scenarios/{name} Delete a scenario
ScenarioConfigurationApi DeleteScenarioList Delete /scenarios Delete all scenarios
ScenarioConfigurationApi GetScenario Get /scenarios/{name} Get a specific scenario
ScenarioConfigurationApi GetScenarioList Get /scenarios Get all scenarios
ScenarioConfigurationApi SetScenario Put /scenarios/{name} Update a scenario
ScenarioExecutionApi ActivateScenario Post /active/{name} Deploy a scenario
ScenarioExecutionApi GetActiveNodeServiceMaps Get /active/serviceMaps Get deployed scenario's port mapping
ScenarioExecutionApi GetActiveScenario Get /active Get the deployed scenario
ScenarioExecutionApi SendEvent Post /events/{type} Send events to the deployed scenario
ScenarioExecutionApi TerminateScenario Delete /active Terminate the deployed scenario

Documentation For Models

Documentation For Authorization

Endpoints do not require authorization.

Author

AdvantEDGE@InterDigital.com

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ContextOAuth2 takes a oauth2.TokenSource as authentication for the request.
	ContextOAuth2 = contextKey("token")

	// ContextBasicAuth takes BasicAuth as authentication for the request.
	ContextBasicAuth = contextKey("basic")

	// ContextAccessToken takes a string oauth2 access token as authentication for the request.
	ContextAccessToken = contextKey("accesstoken")

	// ContextAPIKey takes an APIKey as authentication for the request
	ContextAPIKey = contextKey("apikey")
)

Functions

func CacheExpires

func CacheExpires(r *http.Response) time.Time

CacheExpires helper function to determine remaining time before repeating a request.

Types

type APIClient

type APIClient struct {
	EventReplayApi *EventReplayApiService

	PodStatesApi *PodStatesApiService

	ScenarioConfigurationApi *ScenarioConfigurationApiService

	ScenarioExecutionApi *ScenarioExecutionApiService
	// contains filtered or unexported fields
}

APIClient manages communication with the AdvantEDGE Platform Controller REST API API v1.0.0 In most cases there should be only one, shared, APIClient.

func NewAPIClient

func NewAPIClient(cfg *Configuration) *APIClient

NewAPIClient creates a new API client. Requires a userAgent string describing your application. optionally a custom http.Client to allow for advanced features such as caching.

func (*APIClient) ChangeBasePath

func (c *APIClient) ChangeBasePath(path string)

Change base path to allow switching to mocks

type APIKey

type APIKey struct {
	Key    string
	Prefix string
}

APIKey provides API key based authentication to a request passed via context using ContextAPIKey

type APIResponse

type APIResponse struct {
	*http.Response `json:"-"`
	Message        string `json:"message,omitempty"`
	// Operation is the name of the swagger operation.
	Operation string `json:"operation,omitempty"`
	// RequestURL is the request URL. This value is always available, even if the
	// embedded *http.Response is nil.
	RequestURL string `json:"url,omitempty"`
	// Method is the HTTP method used for the request.  This value is always
	// available, even if the embedded *http.Response is nil.
	Method string `json:"method,omitempty"`
	// Payload holds the contents of the response body (which may be nil or empty).
	// This is provided here as the raw response.Body() reader will have already
	// been drained.
	Payload []byte `json:"-"`
}

func NewAPIResponse

func NewAPIResponse(r *http.Response) *APIResponse

func NewAPIResponseWithError

func NewAPIResponseWithError(errorMessage string) *APIResponse

type ActivateScenarioOpts

type ActivateScenarioOpts struct {
	ActivationInfo optional.Interface
}

type ActivationInfo

type ActivationInfo struct {
	// Replay-file name to execute at deployment time
	ReplayFileName string `json:"replayFileName,omitempty"`
}

Activation information

type BasicAuth

type BasicAuth struct {
	UserName string `json:"userName,omitempty"`
	Password string `json:"password,omitempty"`
}

BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth

type Configuration

type Configuration struct {
	BasePath      string            `json:"basePath,omitempty"`
	Host          string            `json:"host,omitempty"`
	Scheme        string            `json:"scheme,omitempty"`
	DefaultHeader map[string]string `json:"defaultHeader,omitempty"`
	UserAgent     string            `json:"userAgent,omitempty"`
	HTTPClient    *http.Client
}

func NewConfiguration

func NewConfiguration() *Configuration

func (*Configuration) AddDefaultHeader

func (c *Configuration) AddDefaultHeader(key string, value string)

type Deployment

type Deployment struct {
	// Latency in ms between domains
	InterDomainLatency int32 `json:"interDomainLatency,omitempty"`
	// Latency variation in ms between domains
	InterDomainLatencyVariation int32 `json:"interDomainLatencyVariation,omitempty"`
	// The limit of the traffic supported between domains
	InterDomainThroughput int32 `json:"interDomainThroughput,omitempty"`
	// Packet lost (in terms of percentage) between domains
	InterDomainPacketLoss float64 `json:"interDomainPacketLoss,omitempty"`
	// Key/Value Pair Map (string, string)
	Meta map[string]string `json:"meta,omitempty"`
	// Key/Value Pair Map (string, string)
	UserMeta map[string]string `json:"userMeta,omitempty"`
	Domains  []Domain          `json:"domains,omitempty"`
}

Network deployment object

type Domain

type Domain struct {
	// Unique domain ID
	Id string `json:"id,omitempty"`
	// Domain name
	Name string `json:"name,omitempty"`
	// Domain type
	Type_ string `json:"type,omitempty"`
	// Latency in ms between zones within domain
	InterZoneLatency int32 `json:"interZoneLatency,omitempty"`
	// Latency variation in ms between zones within domain
	InterZoneLatencyVariation int32 `json:"interZoneLatencyVariation,omitempty"`
	// The limit of the traffic supported between zones within the domain
	InterZoneThroughput int32 `json:"interZoneThroughput,omitempty"`
	// Packet lost (in terms of percentage) between zones within the domain
	InterZonePacketLoss float64 `json:"interZonePacketLoss,omitempty"`
	// Key/Value Pair Map (string, string)
	Meta map[string]string `json:"meta,omitempty"`
	// Key/Value Pair Map (string, string)
	UserMeta map[string]string `json:"userMeta,omitempty"`
	Zones    []Zone            `json:"zones,omitempty"`
}

Operator domain object

type EgressService

type EgressService struct {
	// Service name
	Name string `json:"name,omitempty"`
	// Multi-Edge service name, if any
	MeSvcName string `json:"meSvcName,omitempty"`
	// External node IP address
	Ip string `json:"ip,omitempty"`
	// Service port number
	Port int32 `json:"port,omitempty"`
	// Service protocol (TCP or UDP)
	Protocol string `json:"protocol,omitempty"`
}

External service exposed internally via specific port

type Event

type Event struct {
	// Event name
	Name string `json:"name,omitempty"`
	// Event type
	Type_                             string                             `json:"type,omitempty"`
	EventNetworkCharacteristicsUpdate *EventNetworkCharacteristicsUpdate `json:"eventNetworkCharacteristicsUpdate,omitempty"`
	EventMobility                     *EventMobility                     `json:"eventMobility,omitempty"`
	EventPoasInRange                  *EventPoasInRange                  `json:"eventPoasInRange,omitempty"`
	EventOther                        *EventOther                        `json:"eventOther,omitempty"`
}

Event object

type EventMobility

type EventMobility struct {
	// Name of the network element to be updated
	ElementName string `json:"elementName,omitempty"`
	// Destination element identifier
	Dest string `json:"dest,omitempty"`
}

Mobility Event object

type EventNetworkCharacteristicsUpdate

type EventNetworkCharacteristicsUpdate struct {
	// Name of the network element to be updated
	ElementName string `json:"elementName,omitempty"`
	// Type of the network element to be updated
	ElementType string `json:"elementType,omitempty"`
	// Latency in ms
	Latency int32 `json:"latency,omitempty"`
	// Latency variation in ms
	LatencyVariation int32 `json:"latencyVariation,omitempty"`
	// Throughput limit
	Throughput int32 `json:"throughput,omitempty"`
	// Packet loss percentage
	PacketLoss float64 `json:"packetLoss,omitempty"`
}

Network Characteristics update Event object

type EventOther

type EventOther struct {
	// Other event string
	Event string `json:"event,omitempty"`
}

Other Event object

type EventPoasInRange

type EventPoasInRange struct {
	// UE identifier
	Ue          string   `json:"ue,omitempty"`
	PoasInRange []string `json:"poasInRange,omitempty"`
}

POAs In Range Event object

type EventReplayApiService

type EventReplayApiService service

func (*EventReplayApiService) CreateReplayFile

func (a *EventReplayApiService) CreateReplayFile(ctx context.Context, name string, replayFile Replay) (*http.Response, error)

EventReplayApiService Add a replay file Add a replay file to the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Replay file name
  • @param replayFile Replay-file

func (*EventReplayApiService) CreateReplayFileFromScenarioExec

func (a *EventReplayApiService) CreateReplayFileFromScenarioExec(ctx context.Context, name string, replayInfo ReplayInfo) (*http.Response, error)

EventReplayApiService Generate a replay file from scenario execution events Generate a replay file using events from the latest execution of a scenario

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Replay file name
  • @param replayInfo Replay information

func (*EventReplayApiService) DeleteReplayFile

func (a *EventReplayApiService) DeleteReplayFile(ctx context.Context, name string) (*http.Response, error)

EventReplayApiService Delete a replay file Delete a replay file by name from the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name replay file name

func (*EventReplayApiService) DeleteReplayFileList

func (a *EventReplayApiService) DeleteReplayFileList(ctx context.Context) (*http.Response, error)

EventReplayApiService Delete all replay files Delete all replay files present in the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

func (*EventReplayApiService) GetReplayFile

func (a *EventReplayApiService) GetReplayFile(ctx context.Context, name string) (Replay, *http.Response, error)

EventReplayApiService Get a specific replay file Get a replay file by name from the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Replay file name

@return Replay

func (*EventReplayApiService) GetReplayFileList

func (a *EventReplayApiService) GetReplayFileList(ctx context.Context) (ReplayFileList, *http.Response, error)

EventReplayApiService Get all replay file names Returns a list of all replay files names present in the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

@return ReplayFileList

func (*EventReplayApiService) GetReplayStatus

func (a *EventReplayApiService) GetReplayStatus(ctx context.Context) (ReplayStatus, *http.Response, error)

EventReplayApiService Get status of replay manager Returns status information on the replay manager

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

@return ReplayStatus

func (*EventReplayApiService) LoopReplay

func (a *EventReplayApiService) LoopReplay(ctx context.Context, name string) (*http.Response, error)

EventReplayApiService Loop-Execute a replay file present in the platform store Loop-Execute a replay file present in the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Replay file name

func (*EventReplayApiService) PlayReplayFile

func (a *EventReplayApiService) PlayReplayFile(ctx context.Context, name string) (*http.Response, error)

EventReplayApiService Execute a replay file present in the platform store Execute a replay file present in the platform store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Replay file name

func (*EventReplayApiService) StopReplayFile

func (a *EventReplayApiService) StopReplayFile(ctx context.Context, name string) (*http.Response, error)

EventReplayApiService Stop execution of a replay file Stop execution a replay file

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Replay file name

type ExternalConfig

type ExternalConfig struct {
	IngressServiceMap []IngressService `json:"ingressServiceMap,omitempty"`
	EgressServiceMap  []EgressService  `json:"egressServiceMap,omitempty"`
}

External Process configuration. NOTE: Only valid if 'isExternal' is set.

type GenericSwaggerError

type GenericSwaggerError struct {
	// contains filtered or unexported fields
}

GenericSwaggerError Provides access to the body, error and model on returned errors.

func (GenericSwaggerError) Body

func (e GenericSwaggerError) Body() []byte

Body returns the raw bytes of the response

func (GenericSwaggerError) Error

func (e GenericSwaggerError) Error() string

Error returns non-empty string if there was an error.

func (GenericSwaggerError) Model

func (e GenericSwaggerError) Model() interface{}

Model returns the unpacked model of the error

type GetActiveNodeServiceMapsOpts

type GetActiveNodeServiceMapsOpts struct {
	Node    optional.String
	Type_   optional.String
	Service optional.String
}

type GetStatesOpts

type GetStatesOpts struct {
	Long  optional.String
	Type_ optional.String
}

type GpuConfig

type GpuConfig struct {
	// Requested GPU type
	Type_ string `json:"type,omitempty"`
	// Number of GPUs requested
	Count int32 `json:"count,omitempty"`
}

GPU configuration object

type IngressService

type IngressService struct {
	// Service name (unique or multi-edge)
	Name string `json:"name,omitempty"`
	// Internal service port number
	Port int32 `json:"port,omitempty"`
	// Externally-exposed unique service port in range (30000 - 32767)
	ExternalPort int32 `json:"externalPort,omitempty"`
	// Service protocol (TCP or UDP)
	Protocol string `json:"protocol,omitempty"`
}

Internal service exposed externally via specific port

type NetworkCharacteristics

type NetworkCharacteristics struct {
	// Latency in ms
	Latency int32 `json:"latency,omitempty"`
	// Latency variation in ms
	LatencyVariation int32 `json:"latencyVariation,omitempty"`
	// Throughput limit in Mbps
	Throughput int32 `json:"throughput,omitempty"`
	// Packet loss percentage
	PacketLoss float64 `json:"packetLoss,omitempty"`
}

Network characteristics object

type NetworkLocation

type NetworkLocation struct {
	// Unique network location ID
	Id string `json:"id,omitempty"`
	// Network location name
	Name string `json:"name,omitempty"`
	// Network location type
	Type_ string `json:"type,omitempty"`
	// Latency in ms for all terminal links within network location
	TerminalLinkLatency int32 `json:"terminalLinkLatency,omitempty"`
	// Latency variation in ms for all terminal links within network location
	TerminalLinkLatencyVariation int32 `json:"terminalLinkLatencyVariation,omitempty"`
	// The limit of the traffic supported for all terminal links within the network location
	TerminalLinkThroughput int32 `json:"terminalLinkThroughput,omitempty"`
	// Packet lost (in terms of percentage) for all terminal links within the network location
	TerminalLinkPacketLoss float64 `json:"terminalLinkPacketLoss,omitempty"`
	// Key/Value Pair Map (string, string)
	Meta map[string]string `json:"meta,omitempty"`
	// Key/Value Pair Map (string, string)
	UserMeta          map[string]string  `json:"userMeta,omitempty"`
	PhysicalLocations []PhysicalLocation `json:"physicalLocations,omitempty"`
}

Logical network location object

type NodeServiceMaps

type NodeServiceMaps struct {
	// Unique external node identifier
	Node              string           `json:"node,omitempty"`
	IngressServiceMap []IngressService `json:"ingressServiceMap,omitempty"`
	EgressServiceMap  []EgressService  `json:"egressServiceMap,omitempty"`
}

Node-specific mapping of exposed internal & external services

type PhysicalLocation

type PhysicalLocation struct {
	// Unique physical location ID
	Id string `json:"id,omitempty"`
	// Physical location name
	Name string `json:"name,omitempty"`
	// Physical location type
	Type_ string `json:"type,omitempty"`
	// true: Physical location is external to MEEP false: Physical location is internal to MEEP
	IsExternal              bool     `json:"isExternal,omitempty"`
	NetworkLocationsInRange []string `json:"networkLocationsInRange,omitempty"`
	// Key/Value Pair Map (string, string)
	Meta map[string]string `json:"meta,omitempty"`
	// Key/Value Pair Map (string, string)
	UserMeta  map[string]string `json:"userMeta,omitempty"`
	Processes []Process         `json:"processes,omitempty"`
	// Latency in ms between the physical location and the network (wired interface, air interface)
	LinkLatency int32 `json:"linkLatency,omitempty"`
	// Latency variation in ms between the physical location and the network (wired interface, air interface)
	LinkLatencyVariation int32 `json:"linkLatencyVariation,omitempty"`
	// The limit of the traffic supported between the physical location and the network (wired interface, air interface)
	LinkThroughput int32 `json:"linkThroughput,omitempty"`
	// Packet lost (in terms of percentage) between the physical location and the network (wired interface, air interface)
	LinkPacketLoss float64 `json:"linkPacketLoss,omitempty"`
}

Physical location object

type PodStatesApiService

type PodStatesApiService service

func (*PodStatesApiService) GetStates

func (a *PodStatesApiService) GetStates(ctx context.Context, localVarOptionals *GetStatesOpts) (PodsStatus, *http.Response, error)

type PodStatus

type PodStatus struct {
	// Pod name
	Name string `json:"name,omitempty"`
	// Pod namespace
	Namespace string `json:"namespace,omitempty"`
	// Pod process name
	MeepApp string `json:"meepApp,omitempty"`
	// Pod origin(core, scenario)
	MeepOrigin string `json:"meepOrigin,omitempty"`
	// Pod scenario name
	MeepScenario string `json:"meepScenario,omitempty"`
	// Pod phase
	Phase string `json:"phase,omitempty"`
	// Pod initialized (true/false)
	PodInitialized string `json:"podInitialized,omitempty"`
	// Pod ready (true/false)
	PodReady string `json:"podReady,omitempty"`
	// Pod scheduled (true/false)
	PodScheduled string `json:"podScheduled,omitempty"`
	// Pod unschedulable (true/false)
	PodUnschedulable string `json:"podUnschedulable,omitempty"`
	// Pod error message
	PodConditionError string `json:"podConditionError,omitempty"`
	// Failed container error message
	ContainerStatusesMsg string `json:"containerStatusesMsg,omitempty"`
	// Number of containers that are up
	NbOkContainers string `json:"nbOkContainers,omitempty"`
	// Number of total containers in the pod
	NbTotalContainers string `json:"nbTotalContainers,omitempty"`
	// Number of container failures leading to pod restarts
	NbPodRestart string `json:"nbPodRestart,omitempty"`
	// State that is mapping the kubernetes api state
	LogicalState string `json:"logicalState,omitempty"`
	// Pod creation time
	StartTime string `json:"startTime,omitempty"`
}

type PodsStatus

type PodsStatus struct {
	PodStatus []PodStatus `json:"podStatus,omitempty"`
}

List of all pods status

type Process

type Process struct {
	// Unique process ID
	Id string `json:"id,omitempty"`
	// Process name
	Name string `json:"name,omitempty"`
	// Process type
	Type_ string `json:"type,omitempty"`
	// true: process is external to MEEP false: process is internal to MEEP
	IsExternal bool `json:"isExternal,omitempty"`
	// Docker image to deploy inside MEEP
	Image string `json:"image,omitempty"`
	// Environment variables using the format NAME=\"value\",NAME=\"value\",NAME=\"value\"
	Environment string `json:"environment,omitempty"`
	// Arguments to command executable
	CommandArguments string `json:"commandArguments,omitempty"`
	// Executable to invoke at container start up
	CommandExe     string          `json:"commandExe,omitempty"`
	ServiceConfig  *ServiceConfig  `json:"serviceConfig,omitempty"`
	GpuConfig      *GpuConfig      `json:"gpuConfig,omitempty"`
	ExternalConfig *ExternalConfig `json:"externalConfig,omitempty"`
	// Process status
	Status string `json:"status,omitempty"`
	// Chart location for the deployment of the chart provided by the user
	UserChartLocation string `json:"userChartLocation,omitempty"`
	// Chart values.yaml file location for the deployment of the chart provided by the user
	UserChartAlternateValues string `json:"userChartAlternateValues,omitempty"`
	// Chart supplemental information related to the group (service)
	UserChartGroup string `json:"userChartGroup,omitempty"`
	// Key/Value Pair Map (string, string)
	Meta map[string]string `json:"meta,omitempty"`
	// Key/Value Pair Map (string, string)
	UserMeta map[string]string `json:"userMeta,omitempty"`
	// Latency in ms caused by the application
	AppLatency int32 `json:"appLatency,omitempty"`
	// Latency variation in ms caused by the application
	AppLatencyVariation int32 `json:"appLatencyVariation,omitempty"`
	// The limit of the traffic supported by the application
	AppThroughput int32 `json:"appThroughput,omitempty"`
	// Packet lost (in terms of percentage) caused by the application
	AppPacketLoss float64 `json:"appPacketLoss,omitempty"`
	// Identifier used for process placement in AdvantEDGE cluster
	PlacementId string `json:"placementId,omitempty"`
}

Application or service object

type Replay

type Replay struct {
	// User description of the content of the replay file.
	Description string        `json:"description,omitempty"`
	Events      []ReplayEvent `json:"events,omitempty"`
}

ReplayEvents from the Replay-file

type ReplayEvent

type ReplayEvent struct {
	// Event index
	Index int32 `json:"index,omitempty"`
	// Relative time (ms) an event happened since the begining of a replay sequence
	Time  int32  `json:"time,omitempty"`
	Event *Event `json:"event,omitempty"`
}

Replay event object

type ReplayFileList

type ReplayFileList struct {
	ReplayFiles []string `json:"replay-files,omitempty"`
}

Replay-file list

type ReplayInfo

type ReplayInfo struct {
	// Scenario name
	ScenarioName string `json:"scenarioName,omitempty"`
	// User description of the replay file
	Description string `json:"description,omitempty"`
}

Scenario information

type ReplayStatus

type ReplayStatus struct {
	// Name of the replay file currently running
	ReplayFileRunning string `json:"replayFileRunning,omitempty"`
	// Index of the last ran event
	Index int32 `json:"index,omitempty"`
	// Number of events in the replay file
	MaxIndex int32 `json:"maxIndex,omitempty"`
	// Loop mode enables
	LoopMode bool `json:"loopMode,omitempty"`
	// Total time remaining for the replay file after last event
	TimeRemaining int32 `json:"timeRemaining,omitempty"`
	// Time remaining until the next event for the replay file after last event
	TimeToNextEvent int32 `json:"timeToNextEvent,omitempty"`
}

Replay status object

type Scenario

type Scenario struct {
	// Scenario version
	Version string `json:"version,omitempty"`
	// Unique scenario ID
	Id string `json:"id,omitempty"`
	// Unique scenario name
	Name string `json:"name,omitempty"`
	// User description of the scenario.
	Description string          `json:"description,omitempty"`
	Config      *ScenarioConfig `json:"config,omitempty"`
	Deployment  *Deployment     `json:"deployment,omitempty"`
}

Scenario object

type ScenarioConfig

type ScenarioConfig struct {
	// Visualization configuration
	Visualization string `json:"visualization,omitempty"`
	// Other scenario configuration
	Other string `json:"other,omitempty"`
}

Scenario configuration

type ScenarioConfigurationApiService

type ScenarioConfigurationApiService service

func (*ScenarioConfigurationApiService) CreateScenario

func (a *ScenarioConfigurationApiService) CreateScenario(ctx context.Context, name string, scenario Scenario) (*http.Response, error)

ScenarioConfigurationApiService Add a scenario Add a scenario to the platform scenario store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Scenario name
  • @param scenario Scenario

func (*ScenarioConfigurationApiService) DeleteScenario

func (a *ScenarioConfigurationApiService) DeleteScenario(ctx context.Context, name string) (*http.Response, error)

ScenarioConfigurationApiService Delete a scenario Delete a scenario by name from the platform scenario store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Scenario name

func (*ScenarioConfigurationApiService) DeleteScenarioList

func (a *ScenarioConfigurationApiService) DeleteScenarioList(ctx context.Context) (*http.Response, error)

ScenarioConfigurationApiService Delete all scenarios Delete all scenarios present in the platform scenario store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

func (*ScenarioConfigurationApiService) GetScenario

ScenarioConfigurationApiService Get a specific scenario Get a scenario by name from the platform scenario store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Scenario name

@return Scenario

func (*ScenarioConfigurationApiService) GetScenarioList

ScenarioConfigurationApiService Get all scenarios Returns all scenarios from the platform scenario store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

@return ScenarioList

func (*ScenarioConfigurationApiService) SetScenario

func (a *ScenarioConfigurationApiService) SetScenario(ctx context.Context, name string, scenario Scenario) (*http.Response, error)

ScenarioConfigurationApiService Update a scenario Update a scenario by name in the platform scenario store

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param name Scenario name
  • @param scenario Scenario to add to MEEP store

type ScenarioExecutionApiService

type ScenarioExecutionApiService service

func (*ScenarioExecutionApiService) ActivateScenario

func (a *ScenarioExecutionApiService) ActivateScenario(ctx context.Context, name string, localVarOptionals *ActivateScenarioOpts) (*http.Response, error)

func (*ScenarioExecutionApiService) GetActiveNodeServiceMaps

func (a *ScenarioExecutionApiService) GetActiveNodeServiceMaps(ctx context.Context, localVarOptionals *GetActiveNodeServiceMapsOpts) ([]NodeServiceMaps, *http.Response, error)

func (*ScenarioExecutionApiService) GetActiveScenario

func (a *ScenarioExecutionApiService) GetActiveScenario(ctx context.Context) (Scenario, *http.Response, error)

ScenarioExecutionApiService Get the deployed scenario Get the scenario currently deployed on the platform

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

@return Scenario

func (*ScenarioExecutionApiService) SendEvent

func (a *ScenarioExecutionApiService) SendEvent(ctx context.Context, type_ string, event Event) (*http.Response, error)

ScenarioExecutionApiService Send events to the deployed scenario Generate events towards the deployed scenario. <p><p>Events: <li>Mobility: move a node in the emulated network <li>Network Characteristic: change network characteristics dynamically <li>PoAs-In-Range: provide PoAs in range of a UE (used with Application State Transfer)

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
  • @param type_ Event type
  • @param event Event to send to active scenario

func (*ScenarioExecutionApiService) TerminateScenario

func (a *ScenarioExecutionApiService) TerminateScenario(ctx context.Context) (*http.Response, error)

ScenarioExecutionApiService Terminate the deployed scenario Terminate the scenario currently deployed on the platform

  • @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().

type ScenarioList

type ScenarioList struct {
	Scenarios []Scenario `json:"scenarios,omitempty"`
}

Scenario list

type ServiceConfig

type ServiceConfig struct {
	// Unique service name
	Name string `json:"name,omitempty"`
	// Multi-Edge service name, if any
	MeSvcName string        `json:"meSvcName,omitempty"`
	Ports     []ServicePort `json:"ports,omitempty"`
}

Service object

type ServicePort

type ServicePort struct {
	// Protocol that the application is using (TCP or UDP)
	Protocol string `json:"protocol,omitempty"`
	// Port number that the service is listening on
	Port int32 `json:"port,omitempty"`
	// External port number on which to expose the application (30000 - 32767)  <li>Only one application allowed per external port <li>Scenario builder must configure to prevent conflicts
	ExternalPort int32 `json:"externalPort,omitempty"`
}

Service port object

type Zone

type Zone struct {
	// Unique zone ID
	Id string `json:"id,omitempty"`
	// Zone name
	Name string `json:"name,omitempty"`
	// Zone type
	Type_   string                  `json:"type,omitempty"`
	NetChar *NetworkCharacteristics `json:"netChar,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterFogLatency int32 `json:"interFogLatency,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterFogLatencyVariation int32 `json:"interFogLatencyVariation,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterFogThroughput int32 `json:"interFogThroughput,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterFogPacketLoss float64 `json:"interFogPacketLoss,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterEdgeLatency int32 `json:"interEdgeLatency,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterEdgeLatencyVariation int32 `json:"interEdgeLatencyVariation,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterEdgeThroughput int32 `json:"interEdgeThroughput,omitempty"`
	// **DEPRECATED** As of release 1.3.0, no longer supported
	InterEdgePacketLoss float64 `json:"interEdgePacketLoss,omitempty"`
	// **DEPRECATED** As of release 1.3.0, replaced by netChar latency
	EdgeFogLatency int32 `json:"edgeFogLatency,omitempty"`
	// **DEPRECATED** As of release 1.3.0, replaced by netChar latencyVariation
	EdgeFogLatencyVariation int32 `json:"edgeFogLatencyVariation,omitempty"`
	// **DEPRECATED** As of release 1.3.0, replaced by netChar throughput
	EdgeFogThroughput int32 `json:"edgeFogThroughput,omitempty"`
	// **DEPRECATED** As of release 1.3.0, replaced by netChar packetLoss
	EdgeFogPacketLoss float64 `json:"edgeFogPacketLoss,omitempty"`
	// Key/Value Pair Map (string, string)
	Meta map[string]string `json:"meta,omitempty"`
	// Key/Value Pair Map (string, string)
	UserMeta         map[string]string `json:"userMeta,omitempty"`
	NetworkLocations []NetworkLocation `json:"networkLocations,omitempty"`
}

Logical zone (MEC network) object

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL