Subscription Service
Protobuf Definition#
service SubscriptionService { rpc SubscribeToLsNodes(TopologySubscription) returns (stream LsNodeEvent) {} rpc SubscribeToLsLinks(TopologySubscription) returns (stream LsLinkEvent) {} rpc SubscribeToLsPrefixes(TopologySubscription) returns (stream LsPrefixEvent) {} rpc SubscribeToLsSrv6Sids(TopologySubscription) returns (stream LsSrv6SidEvent) {} rpc SubscribeToLsNodeEdges(TopologySubscription) returns (stream LsNodeEdgeEvent) {} rpc SubscribeToPeers(TopologySubscription) returns (stream PeerEvent) {} rpc SubscribeToTelemetryData(TelemetrySubscription) returns (stream TelemetryEvent) {}}Methods#
SubscribeToLsNodes()#
rpc SubscribeToLsNodes(TopologySubscription) returns (stream LsNodeEvent) {}See also: TopologySubscription, LsNodeEvent
Description#
Takes a TopologySubscription with the specified keys and properties and returns a stream of LsNodeEvents. An LsNodeEvent contains an update to a single LsNode. Only LsNodes matching one of the specified keys are returned and only properties specified in properties are set.
- Omitting keys streams LsNodeEvents for all available LsNodes.
- Omitting properties streams LsNodeEvents for LsNodes with all available properties.
Examples#
Example 1
TopologySubscription { "keys": [ "nodeKey1", "nodeKey2" ], "properties": [ "Key", "Name", "Asn" ]}// Continuously streams LsNodeEvents// only for the specified nodes and// returns only the specified properties
LsNodeEvent { "Action": "update", "Key": "nodeKey1", "LsNode": { "Key": "nodeKey1", "Name": "XR-1", "Asn": 65001, }}Example 2
TopologySubscription { "properties": [ "Key", "Name", "Asn" ]}// Continuously streams LsNodeEvents// for all available nodes and returns// only the specified properties
LsNodeEvent { "Action": "update", "Key": "nodeKey7", "LsNode": { "Key": "nodeKey7", "Name": "XR-7", "Asn": 65001, }}Example 3
TopologySubscription { "keys": [ "nodeKey1", "nodeKey2" ],}// Continuously streams LsNodeEvents// for the specified nodes
LsNodeEvent { "Action": "update", "Key": "nodeKey1", "LsNode": { "Key": "nodeKey1", "Id": 773, "RouterHash": "7eb583cb3c17c496cfa9370d9bc2a3eb", ... }}Example 4
TopologySubscription {}// Continuously streams LsNodeEvents// for all available nodes
LsNodeEvent { "Action": "update", "Key": "nodeKey7", "LsNode": { "Key": "nodeKey7", "Id": 773, "RouterHash": "7eb583cb3c17c496cfa9370d9bc2a3eb", ... }}SubscribeToLsLinks()#
rpc SubscribeToLsLinks(TopologySubscription) returns (stream LsLinkEvent) {}See also: TopologySubscription, LsLinkEvent
Description#
See method SubscribeToLsNodes(). It follows the same principle regarding keys and properties.
SubscribeToLsPrefixes()#
rpc SubscribeToLsPrefixes(TopologySubscription) returns (stream LsPrefixEvent) {}See also: TopologySubscription, LsPrefixEvent
Description#
See method SubscribeToLsNodes(). It follows the same principle regarding keys and properties.
SubscribeToLsSrv6Sids()#
rpc SubscribeToLsSrv6Sids(TopologySubscription) returns (stream LsSrv6SidEvent) {}See also: TopologySubscription, LsSrv6SidEvent
Description#
See method SubscribeToLsNodes(). It follows the same principle regarding keys and properties.
SubscribeToLsNodeEdges()#
rpc SubscribeToLsNodeEdges(TopologySubscription) returns (stream LsNodeEdgeEvent) {}See also: TopologySubscription, LsNodeEdgeEvent
Description#
See method SubscribeToLsNodes(). It follows the same principle regarding keys and properties.
SubscribeToPeers#
rpc SubscribeToPeers(TopologySubscription) returns (stream PeerEvent) {}See also: PeerSubscription, PeerEvent
Description#
See method SubscribeToLsNodes(). It follows the same principle regarding keys and properties.
SubscribeToTelemetryData()#
rpc SubscribeToTelemetryData(TelemetrySubscription) returns (stream TelemetryEvent) {}See also: TelemetrySubscription, TelemetryResponse
Description#
Subscribing to telemetry data follows the same principle as requesting telemetry data. For reference, see GetTelemetryData().
SubscribeToTelemetryData() does not allow you to provide RangeFilters however, unlike GetTelemetryData().