Table of Contents

Class GrpcServer

Namespace
IdeaStatiCa.Plugin.Grpc
Assembly
IdeaStatiCa.Plugin.dll

Server implementation for the Grpc connection.

public class GrpcServer : IGrpcServer, IGrpcCommunicator

Inheritance

Derived

Implements

Inherited Members

Constructors

GrpcServer(IPluginLogger, IGrpcService, IBlobStorageProvider)

Initializes the IdeaStatiCa Grpc server.

public GrpcServer(IPluginLogger logger, IGrpcService grpcService, IBlobStorageProvider blobStorageProvider = null)

Parameters

logger IPluginLogger

Logger

grpcService IGrpcService
blobStorageProvider IBlobStorageProvider

Provider of blob storages

Fields

Logger

public readonly IPluginLogger Logger

Field Value

IPluginLogger

Properties

ClientID

Returns ID of currently connected client.

public string ClientID { get; }

Property Value

string

GrpcService

grpc service for bi-directional streaming messaging

public IGrpcService GrpcService { get; }

Property Value

IGrpcService

Host

The host

public string Host { get; }

Property Value

string

Port

Port on which the server will communicate.

public int Port { get; }

Property Value

int

Methods

StartAsync(string, int)

Starts the server.

public Task StartAsync(string clientId, int port)

Parameters

clientId string

Current client ID (PID)

port int

Port on which the server is running.

Returns

Task

StopAsync()

Requests server to shutdown

public Task StopAsync()

Returns

Task