Table of Contents

Class GnmiClient

Namespace
Skyline.DataMiner.DataSources.OpenConfig.Gnmi.Api
Assembly
Skyline.DataMiner.DataSources.OpenConfig.Gnmi.dll

A class that represents a single gRPC connection which can be used to handle gNMI communication. This requires the CommunicationGateway DxM to be available.

'Channel' refers to a virtual connection to a conceptual endpoint in the DxM. 'Connection' refers to an active gRPC (HTTP2) connection with an endpoint. 'DataSource' refers to a conceptual endpoint and its identifying parameters. 'Node' refers to a location in the OpenConfig schema, represented by a path. A node can be a leaf, a container, a list, ...

public class GnmiClient
Inheritance
GnmiClient
Extension Methods

Constructors

GnmiClient(uint, uint, string, DataSourceConfiguration, ILogger)

Constructs a gNMI/gRPC client that will use the CommunicationGateway DxM to connect to a device. The connection is only set up when Connect() is called.

Properties

IsConnected

Gets a boolean indicating if there is a connection with the channel.

Methods

Capabilities()

Get the capabilities of the endpoint.

ChangeConfiguration(DataSourceConfiguration)

When the configuration is different, this will trigger a disconnect and update the data source configuration to then reconnect.

Connect()

Registers the channel with a CommunicationGateway DxM and makes the DxM attempt a connection with the endpoint.

Disconnect()

Closes the connection with the endpoint and unregisters the channel with the DxM.

Dispose()

The dispose will also call Disconnect.

Dispose(bool)

Disposing the object.

Get(IEnumerable<Path>)

Get the gNMI values for the specified paths.

Get(IEnumerable<string>)

Get the gNMI values for the specified paths.

GetMessageBroker()

Creates a new message broker.

OnConnectionStateChanged(EventArgs)

Triggers the execution of the ConnectionStateChanged event handler.

Set(Path, string)

Sets the value for a specific path.

Set(string, string)

Sets the value for a specific path.

SetDataMapper(IDataMapper)

Sets the data mapper that will process incoming messages. An SLProtocol compatible implementation is available in the Skyline.DataMiner.DataSources.OpenConfig.Gnmi.Protocol Nuget: DataMinerConnectorDataMapper.

Subscribe(string, IEnumerable<Path>, Action<IEnumerable<GnmiResponseValue>>)

Adds a subscription for changed values on the endpoint for the specified paths.

Subscribe(string, IEnumerable<string>, Action<IEnumerable<GnmiResponseValue>>)

Adds a subscription for changed values on the endpoint for the specified paths.

Subscribe(string, TimeSpan, IEnumerable<Path>, Action<IEnumerable<GnmiResponseValue>>)

Adds a subscription with a sample interval on the endpoint for the specified paths.

Subscribe(string, TimeSpan, IEnumerable<string>, Action<IEnumerable<GnmiResponseValue>>)

Adds a subscription with a sample interval on the endpoint for the specified paths.

Unsubscribe(string)

Removes a subscription from the endpoint.

Events

ConnectionStateChanged

Action that will be called when the connection state changed.