@@ -17,7 +17,10 @@ syntax = "proto3";
17
17
18
18
import "google/protobuf/any.proto" ;
19
19
import "google/protobuf/descriptor.proto" ;
20
- import "juniper_gnmi_ext.proto" ;
20
+ import public "gnmi_ext.proto" ;
21
+ //import "github.com/openconfig/gnmi/proto/gnmi_ext/gnmi_ext.proto";
22
+ //import "github.com/openconfig/gnmi/proto/gnmi_ext/gnmi_ext.proto";
23
+ //import "gnmi_ext.proto";
21
24
22
25
// Package gNMI defines a service specification for the gRPC Network Management
23
26
// Interface. This interface is defined to be a standard interface via which
@@ -37,7 +40,13 @@ extend google.protobuf.FileOptions {
37
40
38
41
// gNMI_service is the current version of the gNMI service, returned through
39
42
// the Capabilities RPC.
40
- option (gnmi_service) = "0.7.0" ;
43
+ option (gnmi_service) = "0.8.0" ;
44
+
45
+ option go_package = "github.com/openconfig/gnmi/proto/gnmi" ;
46
+ option java_multiple_files = true ;
47
+ option java_outer_classname = "GnmiProto" ;
48
+ option java_package = "com.github.gnmi.proto" ;
49
+
41
50
42
51
service gNMI {
43
52
// Capabilities allows the client to retrieve the set of capabilities that
@@ -111,8 +120,9 @@ message TypedValue {
111
120
uint64 uint_val = 3 ; // Unsigned integer value.
112
121
bool bool_val = 4 ; // Bool value.
113
122
bytes bytes_val = 5 ; // Arbitrary byte sequence value.
114
- float float_val = 6 ; // Floating point value.
115
- Decimal64 decimal_val = 7 ; // Decimal64 encoded value.
123
+ float float_val = 6 [deprecated =true ]; // Deprecated - use double_val.
124
+ double double_val = 14 ; // Floating point value.
125
+ Decimal64 decimal_val = 7 [deprecated =true ]; // Deprecated - use double_val.
116
126
ScalarArray leaflist_val = 8 ; // Mixed type scalar array value.
117
127
google.protobuf.Any any_val = 9 ; // protobuf.Any encoded bytes.
118
128
bytes json_val = 10 ; // JSON-encoded text.
@@ -121,7 +131,7 @@ message TypedValue {
121
131
// Protobuf binary encoded bytes. The message type is not included.
122
132
// See the specification at
123
133
// github.com/openconfig/reference/blob/master/rpc/gnmi/protobuf-vals.md
124
- // for a complete specification.
134
+ // for a complete specification. [Experimental]
125
135
bytes proto_bytes = 13 ;
126
136
}
127
137
}
@@ -137,10 +147,10 @@ message Path {
137
147
string origin = 2 ; // Label to disambiguate path.
138
148
repeated PathElem elem = 3 ; // Elements of the path.
139
149
string target = 4 ; // The name of the target
140
- // (Sec. 2.2.2.1)
150
+ // (Sec. 2.2.2.1)
141
151
}
142
152
143
- // PathElem encodes an element of a gNMI path, along ith any attributes (keys)
153
+ // PathElem encodes an element of a gNMI path, along with any attributes (keys)
144
154
// that may be associated with it.
145
155
// Reference: gNMI Specification Section 2.2.2.
146
156
message PathElem {
@@ -165,7 +175,7 @@ message Value {
165
175
enum Encoding {
166
176
JSON = 0 ; // JSON encoded text.
167
177
BYTES = 1 ; // Arbitrarily encoded bytes.
168
- PROTO = 2 ; // Encoded according to out-of-band agreed Protobuf .
178
+ PROTO = 2 ; // Encoded according to scalar values of TypedValue .
169
179
ASCII = 3 ; // ASCII text of an out-of-band agreed format.
170
180
JSON_IETF = 4 ; // JSON encoded text as per RFC7951.
171
181
}
@@ -285,7 +295,7 @@ message Subscription {
285
295
Path path = 1 ; // The data tree path.
286
296
SubscriptionMode mode = 2 ; // Subscription mode to be used.
287
297
uint64 sample_interval = 3 ; // ns between samples in SAMPLE mode.
288
- // Indicates whether values that not changed should be sent in a SAMPLE
298
+ // Indicates whether values that have not changed should be sent in a SAMPLE
289
299
// subscription.
290
300
bool suppress_redundant = 4 ;
291
301
// Specifies the maximum allowable silent period in nanoseconds when
@@ -455,3 +465,37 @@ message ModelData {
455
465
string version = 3 ; // Semantic version of the model.
456
466
}
457
467
468
+ service gNMIDialOut {
469
+ // Publish allows the target to send telemetry updates (in the form of
470
+ // SubscribeResponse messages, which have the same semantics as in the
471
+ // gNMI Subscribe RPC, to a client. The client may optionally return the
472
+ // PublishResponse message in response to the dial-out connection from the
473
+ // target. In this case, the client may modify the set of subscriptions
474
+ // that are to be published by the target by:
475
+ // - Specifying a client_id within the PublishResponse message. In this
476
+ // case the target should match pre-configured subscriptions the specified
477
+ // client_id, and send data only for the paths associated with the
478
+ // specified client_id.
479
+ // - Specifying a SubscribeRequest message within the subscriptions field of
480
+ // the PublishResponse message. This message has the same semantics as
481
+ // in the Subscribe gNMI RPC.
482
+ // In the case that the client specifies neither option, a default set of
483
+ // subscriptions (which should be configurable on the target) should be
484
+ // published to the client (collector).
485
+ //
486
+ // The configuration of subscriptions associated with the publish RPC may
487
+ // be through the OpenConfig telemetry configuration and operational state
488
+ // model:
489
+ // https://github.com/openconfig/public/blob/master/release/models/telemetry/openconfig-telemetry.yang
490
+ rpc Publish (stream SubscribeResponse ) returns (stream PublishResponse );
491
+ }
492
+
493
+ // PublishResponse is the message sent within the Publish RPC of the gNMI
494
+ // dial-out service by the client (collector) to the target. It is used to
495
+ // modify the set of paths that are to be sent by the target to the collector.
496
+ message PublishResponse {
497
+ oneof request {
498
+ string client_id = 1 ; // A string identifying the client to the target.
499
+ SubscribeRequest subscriptions = 2 ; // Optional specification of the subscriptions.
500
+ }
501
+ }
0 commit comments