The Streaming Telemetry UDR Types (3.3)

The UDR type created in the Streaming Telemetry agent can be viewed in the UDR Internal Format Browser. To open the browser right-click in the editing area of an APL Editor and select UDR Assistance.... The browser opens.

How to Split a Request

Routers impose limits to the number of paths that can be present in a subscription request. In case more paths are needed, it is possible to split a request so that the agent sends two or more requests with fewer paths in each one. APL can be used to perform this split.

Both StreamingTelemetrySessionUDR.subscribeRequest.gnmiRequest and StreamingTelemetrySessionUDR.subscribeRequest.jtiRequest are lists of SubscribeRequest and SubscriptionRequest items, respectively.

The agent treats StreamingTelemetrySessionUDR as a single request identified by the sessionKey. However, if the list in the subscribeRequest contains multiple items, then multiple subscriptions are sent to the router. When a new StreamingTelemetrySessionUDR with the same sessionKey is received by the agent, all the previous subscriptions associated with that sessionKey are cancelled and a new set of subscriptions are sent.

Input UDRs

StreamingTelemetrySessionUDR

This UDR is used to trigger a new subscription based on the paths defined in the JTI or gNMI UDR. Available fields are:

Field

Description

Field

Description

connectionAction (ConnectionAction)

Use this field to tell the agent whether to connect or disconnect.

context (any)

This is an internal working field that can be used in the workflow configuration to keep track of and use internal workflow information related to the request, when processing the answer.

password (string)

Password to log into the gNMI or JTI server.

username (string)

Username to log into the gNMI or JTI server.

serverHost (string)

Address of host to send request to.

serverPort (int)

Port of host to send request to.

sessionKey (string)

Unique identifier for this session. This key is only used by the agent.

subscribeRequest (RequestType)

UDR to define the request. For more information see description of RequestType.

ConnectionAction

Available field:

Field

Description

Field

Description

value (int)

The value can be one of DISCONNECT, NEW_CONNECTION, or UPDATE_CONNECTION, which are present in the UDR as constants.

RequestType

Set one of the gnmiRequest or jtiRequest. The one latest set will be used. The field requestCase decides which one is used. Available fields are:

Field

Description

Field

Description

gnmiRequest (list<GnmiSubscribeRequest>)

A list of subscribe requests as defined in the gNMI proto file.

jtiRequest (list<JtiSubscriptionRequest>)

A list of subscribe requests as defined in the telemetry proto file.

requestCase (int)

The value can be one of JTI_TYPE, GNMI_TYPE, or NOT_DEFINED.

Output UDRs

StreamingTelemetryResponseUDR

Contains information subscribed to in the triggering session UDR. This UDR is sent out at the intervals configured in the session UDR, according to the corresponding protocol.

Available fields are:

Field

Description

Field

Description

response(ResponseType)

The UDR that holds the response.

session (StreamingTelemetrySessionUDR)

The UDR that triggered the subscription.

sessionKey (string)

Unique identifier for this session. This key is only used by the agent.

ResponseType

Contains one of the gnmiResponse or jtiResponse. The field requestCase decides which one is used. Available fields are:

Field

Description

Field

Description

gnmiResponse(SubscribeResponse)

Subscribe response as defined in the gNMI proto file.

jtiResponse (OpenConfigData)

Subscribe response as defined in the telemetry proto file.

error (Error)

UDR to describe an error.

responseCase (int)

The value can be one of JTI_TYPE, GNMI_TYPE, ERROR_TYPE or NOT_DEFINED.

Error

Available fields are:

Field

Description

Field

Description

code (int)

Error code from gRPC layer, or minus one (-1) if not defined.

message (string)

The error message.

The oneOf type in gNMI

For gNMI (in gRPC) there is a type called oneOf, which corresponds to the standard function of a Radio Button, meaning that only one field value can be chosen at any one time. In APL this is implemented so that there are two fields; one for all the possible field values, and one for specifying the value chosen.

The field values are available as constants. However, the SubscribeResponse constants are not available in the UDR externally, they are only available internally in .

To clarify, for SubscribeResponse there is a field called "responseType" with the field values 0, 1, 3, and 4, where:

0 = No value is set

1 = UPDATE

3 = SyncResponse

4 = Error (deprecated)

These values match the gNMI SubscribeResponse type.