Repository navigation
Expand file tree
/
Copy pathbfd_service.proto
More file actions
121 lines (103 loc) · 4.31 KB
/
Copy pathbfd_service.proto
File metadata and controls
121 lines (103 loc) · 4.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
/**********************************************************************************************************************
* Description: interface between router agents and SDK service manager
*
* Copyright (c) 2018 Nokia
**********************************************************************************************************************/
// NDK Version: v0.5.0
syntax = "proto3";
package srlinux.sdk;
import "ndk/sdk_common.proto";
option go_package = "github.com/nokia/srlinux-ndk-go/ndk";
/**
* Represents BFD session subscription request.
*/
message BfdSessionSubscriptionRequest {
BfdGeneralSessionKey key = 1; // Optional, to filter on name
}
/*
When getting the session status via the GeneralSessionData entry, the status corresponds to the meaning in RFC 5880.
When a protocol (such as BGP) is getting a session status update, the meaning of each state is as follows:
ADMIN_DOWN means one end of the session is admin down so the session is not monitoring connectivity.
DOWN means the session has failed
(INIT is only provided via the GeneralSessionData)
UP means the session is established and working normally
*/
// Represents BFD session status.
enum BfdSessionStatus {
BFD_SESSION_STATUS_INVALID = 0; // Session invalid/unspecified
BFD_SESSION_STATUS_ADMIN_DOWN = 1; // Admin down
BFD_SESSION_STATUS_DOWN = 2; // Status down
BFD_SESSION_STATUS_INIT = 3; // Status initializing
BFD_SESSION_STATUS_UP = 4; // Status up and running
}
// Represents BFD session type.
enum BfdSessionType {
BFD_SESSION_TYPE_UNKNOWN = 0; // Unknown session type
BFD_SESSION_TYPE_P2P = 1; // Peer-to-peer session type
BFD_SESSION_TYPE_MICROBFD = 2; // microbfd session type
BFD_SESSION_TYPE_SBFD_ECHO = 3; // seamless BFD session type, echo initiator
}
/**********************************************************************************************************************
* general session info db_key: bfd_mgr:bfd-general-session-info
* key [BfdGeneralSessionKey] : Key information to uniquely identify session
* data [BfdGeneralSessionData]: Information about the specified session
***********************************************************************************************************************/
/**
* Represents BFD session key.
*/
message BfdGeneralSessionKey {
message P2pKey {
IpAddressPb source_ip_address = 1; // Source IP address of the session
IpAddressPb destination_ip_address = 2; // Destination IP address of the session
uint32 instance_id = 3; // Network instance identifier
uint32 ipv4_unnumbered_or_ipv6_ll_interface_id = 4; // Global if id for ipv4 unnumbered or ipv6 link local
// session, otherwise 0
bool specified_discriminator = 5; // True if discriminators are specified
}
message MicrobfdKey {
string interface_name = 1;
}
message SbfdechoKey {
enum SrpolicyUserType {
SRPOLICY_USER_TYPE_LOCAL = 0;
SRPOLICY_USER_TYPE_TYPE_PCEP = 1;
}
uint32 instance_id = 1; // Network instance identifier
uint32 sr_policy_segment_list_id = 2;
string policy_name = 3;
SrpolicyUserType user_type = 4;
IpAddressPb sr_policy_endpoint = 5;
}
// type is always present, other key field presence is determined by type
BfdSessionType type = 10; // Session type
oneof key {
P2pKey p2p = 20;
MicrobfdKey microbfd = 30;
SbfdechoKey sbfdecho = 40;
}
}
/**
* Represents BFD session data.
*/
message BfdGeneralSessionData {
// Represents BFD session subtype.
enum BfdSessionSubType {
BFD_SESSION_SUB_TYPE_UNKNOWN = 0; // Session subtype unknown
BFD_SESSION_SUB_TYPE_SINGLE_HOP = 1; // Single-hop session
BFD_SESSION_SUB_TYPE_MULTI_HOP = 2; // Multi-hop session
BFD_SESSION_SUB_TYPE_MICROBFD = 3; // microbfd session
BFD_SESSION_SUB_TYPE_SBFD_ECHO = 4; // microbfd session
}
BfdSessionStatus status = 1; // Status of the session
BfdSessionSubType subscription_type = 2; // Subtype of the session
// source_interface_id is only populated for P2P type
uint32 source_interface_id = 3; // Source interface ID
}
/**
* Represents BFD session notification.
*/
message BfdSessionNotification {
SdkMgrOperation op = 1; // Operation such as session create, delete, or update
BfdGeneralSessionKey key = 2; // Session key
BfdGeneralSessionData data = 3; // Session data
}