From d2955d9aaca409c924cee039df09141b06dd7386 Mon Sep 17 00:00:00 2001 From: sodn Date: Wed, 6 Nov 2024 20:18:37 +0530 Subject: [PATCH 1/7] updating the version in proto packages and modified the import --- connector/setup.py | 12 +++++++----- .../src/yang/connector/proto/protofiles/gnmi.proto | 2 +- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/connector/setup.py b/connector/setup.py index 90bc674d..b2074c2a 100755 --- a/connector/setup.py +++ b/connector/setup.py @@ -179,11 +179,13 @@ def find_version(*paths): # package dependencies install_requires = [ - 'paramiko >= 1.15.1', - 'lxml >= 3.3.0, <5.0.0', - 'ncclient >= 0.6.6', - 'grpcio', - 'protobuf' + 'paramiko >= 3.5.0', + 'lxml >= 4.9.4, <5.0.0', + 'ncclient >= 0.6.16', + 'grpcio >= 1.67.1', + 'grpcio-tools >= 1.67.1', + 'googleapis-common-protos >= 1.65.0', + 'protobuf >= 5.28.3' ], # any additional groups of dependencies. diff --git a/connector/src/yang/connector/proto/protofiles/gnmi.proto b/connector/src/yang/connector/proto/protofiles/gnmi.proto index c50394fb..da779f65 100644 --- a/connector/src/yang/connector/proto/protofiles/gnmi.proto +++ b/connector/src/yang/connector/proto/protofiles/gnmi.proto @@ -17,7 +17,7 @@ syntax = "proto3"; import "google/protobuf/any.proto"; import "google/protobuf/descriptor.proto"; -import "github.com/openconfig/gnmi/proto/gnmi_ext/gnmi_ext.proto"; +import "gnmi_ext.proto"; // Package gNMI defines a service specification for the gRPC Network Management // Interface. This interface is defined to be a standard interface via which From 8a7d81b2ae325921105c1fbe2730f00931ec322f Mon Sep 17 00:00:00 2001 From: sodn Date: Wed, 6 Nov 2024 20:35:20 +0530 Subject: [PATCH 2/7] Updation that the latest gnmi_ext.proto supports the 'Commit' option --- .../connector/proto/protofiles/gnmi_ext.proto | 50 +++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto index 142fe1d2..28c2d853 100644 --- a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto +++ b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto @@ -89,3 +89,53 @@ message TimeRange { int64 start = 1; // Nanoseconds since the epoch int64 end = 2; // Nanoseconds since the epoch } +// Commit confirmed extension allows automated revert of the configuration after +// certain duration if an explicit confirmation is not issued. It allows +// explicit cancellation of the commit during the rollback window. There cannot +// be more than one commit active at a given time. The document about gNMI +// commit confirmed can be found at +// https://github.com/openconfig/reference/blob/master/rpc/gnmi/gnmi-commit-confirmed.md +message Commit { + // ID is provided by the client during the commit request. During confirm and + // cancel actions the provided ID should match the ID provided during commit. + // If ID is not passed in any actions server shall return error. + // Required. + string id = 1; + oneof action { + // commit action creates a new commit. If a commit is on-going, server + // returns error. + CommitRequest commit = 2; + // confirm action will confirm an on-going commit, the ID provided during + // confirm should match the on-going commit ID. + CommitConfirm confirm = 3; + // cancel action will cancel an on-going commit, the ID provided during + // cancel should match the on-going commit ID. + CommitCancel cancel = 4; + // set rollback duration action sets the rollback duration of an on-going commit + // to a new value. + // The ID provided with the Commit message should match the on-going commit ID. + CommitSetRollbackDuration set_rollback_duration = 5; + } +} + +// CommitRequest is used to create a new confirmed commit. It hold additional +// parameter requried for commit action. +message CommitRequest { + // Maximum duration to wait for a confirmaton before reverting the commit. + google.protobuf.Duration rollback_duration = 1; +} + +// CommitConfirm is used to confirm an on-going commit. It hold additional +// parameter requried for confirm action. +message CommitConfirm {} + +// CommitCancel is used to cancel an on-going commit. It hold additional +// parameter requried for cancel action. +message CommitCancel {} + +// CommitSetRollbackDuration is used to set the existing rollback duration value +// of an on-going commit to a new desired value. +message CommitSetRollbackDuration { + // Maximum duration to wait for a confirmaton before reverting the commit. + google.protobuf.Duration rollback_duration = 1; +} \ No newline at end of file From 544fc3ffc416b37b2f5674972a6dd0a70f6511a1 Mon Sep 17 00:00:00 2001 From: sodn Date: Thu, 7 Nov 2024 10:49:42 +0530 Subject: [PATCH 3/7] Updated commit in extension --- connector/src/yang/connector/proto/protofiles/gnmi_ext.proto | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto index 28c2d853..168d4556 100644 --- a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto +++ b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto @@ -29,7 +29,9 @@ message Extension { RegisteredExtension registered_ext = 1; // A registered extension. // Well known extensions. MasterArbitration master_arbitration = 2; // Master arbitration extension. - History history = 3; // History extension. + History history = 3; + Commit commit = 4; + Depth depth = 5; // History extension. } } From f1c038326917517601ed123594af2355c68f8d99 Mon Sep 17 00:00:00 2001 From: sodn Date: Thu, 7 Nov 2024 10:50:47 +0530 Subject: [PATCH 4/7] Updated changes --- connector/src/yang/connector/proto/protofiles/gnmi_ext.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto index 168d4556..81aee2ca 100644 --- a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto +++ b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto @@ -29,7 +29,7 @@ message Extension { RegisteredExtension registered_ext = 1; // A registered extension. // Well known extensions. MasterArbitration master_arbitration = 2; // Master arbitration extension. - History history = 3; + History history = 3; // History extension. Commit commit = 4; Depth depth = 5; // History extension. } From 37af82d155b5cfa689eb2431315169c144653c69 Mon Sep 17 00:00:00 2001 From: sodn Date: Fri, 8 Nov 2024 17:23:50 +0530 Subject: [PATCH 5/7] Added proto changes --- .../src/yang/connector/proto/gnmi_ext_pb2.py | 142 +++--- .../yang/connector/proto/gnmi_ext_pb2_grpc.py | 21 + .../src/yang/connector/proto/gnmi_pb2.py | 413 +++++------------- .../src/yang/connector/proto/gnmi_pb2_grpc.py | 93 +++- .../connector/proto/protofiles/gnmi.proto | 17 +- .../connector/proto/protofiles/gnmi_ext.proto | 36 +- 6 files changed, 294 insertions(+), 428 deletions(-) diff --git a/connector/src/yang/connector/proto/gnmi_ext_pb2.py b/connector/src/yang/connector/proto/gnmi_ext_pb2.py index 713e35fe..a8e1a816 100644 --- a/connector/src/yang/connector/proto/gnmi_ext_pb2.py +++ b/connector/src/yang/connector/proto/gnmi_ext_pb2.py @@ -1,102 +1,64 @@ # -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! +# NO CHECKED-IN PROTOBUF GENCODE # source: gnmi_ext.proto +# Protobuf Python Version: 5.27.2 """Generated protocol buffer code.""" -from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import descriptor_pool as _descriptor_pool -from google.protobuf import message as _message -from google.protobuf import reflection as _reflection +from google.protobuf import runtime_version as _runtime_version from google.protobuf import symbol_database as _symbol_database +from google.protobuf.internal import builder as _builder +_runtime_version.ValidateProtobufRuntimeVersion( + _runtime_version.Domain.PUBLIC, + 5, + 27, + 2, + '', + 'gnmi_ext.proto' +) # @@protoc_insertion_point(imports) _sym_db = _symbol_database.Default() - - -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x0egnmi_ext.proto\x12\x08gnmi_ext\"\xac\x01\n\tExtension\x12\x37\n\x0eregistered_ext\x18\x01 \x01(\x0b\x32\x1d.gnmi_ext.RegisteredExtensionH\x00\x12\x39\n\x12master_arbitration\x18\x02 \x01(\x0b\x32\x1b.gnmi_ext.MasterArbitrationH\x00\x12$\n\x07history\x18\x03 \x01(\x0b\x32\x11.gnmi_ext.HistoryH\x00\x42\x05\n\x03\x65xt\"E\n\x13RegisteredExtension\x12!\n\x02id\x18\x01 \x01(\x0e\x32\x15.gnmi_ext.ExtensionID\x12\x0b\n\x03msg\x18\x02 \x01(\x0c\"Y\n\x11MasterArbitration\x12\x1c\n\x04role\x18\x01 \x01(\x0b\x32\x0e.gnmi_ext.Role\x12&\n\x0b\x65lection_id\x18\x02 \x01(\x0b\x32\x11.gnmi_ext.Uint128\"$\n\x07Uint128\x12\x0c\n\x04high\x18\x01 \x01(\x04\x12\x0b\n\x03low\x18\x02 \x01(\x04\"\x12\n\x04Role\x12\n\n\x02id\x18\x01 \x01(\t\"S\n\x07History\x12\x17\n\rsnapshot_time\x18\x01 \x01(\x03H\x00\x12$\n\x05range\x18\x02 \x01(\x0b\x32\x13.gnmi_ext.TimeRangeH\x00\x42\t\n\x07request\"\'\n\tTimeRange\x12\r\n\x05start\x18\x01 \x01(\x03\x12\x0b\n\x03\x65nd\x18\x02 \x01(\x03*3\n\x0b\x45xtensionID\x12\r\n\tEID_UNSET\x10\x00\x12\x15\n\x10\x45ID_EXPERIMENTAL\x10\xe7\x07\x42+Z)github.com/openconfig/gnmi/proto/gnmi_extb\x06proto3') - -_EXTENSIONID = DESCRIPTOR.enum_types_by_name['ExtensionID'] -ExtensionID = enum_type_wrapper.EnumTypeWrapper(_EXTENSIONID) -EID_UNSET = 0 -EID_EXPERIMENTAL = 999 - - -_EXTENSION = DESCRIPTOR.message_types_by_name['Extension'] -_REGISTEREDEXTENSION = DESCRIPTOR.message_types_by_name['RegisteredExtension'] -_MASTERARBITRATION = DESCRIPTOR.message_types_by_name['MasterArbitration'] -_UINT128 = DESCRIPTOR.message_types_by_name['Uint128'] -_ROLE = DESCRIPTOR.message_types_by_name['Role'] -_HISTORY = DESCRIPTOR.message_types_by_name['History'] -_TIMERANGE = DESCRIPTOR.message_types_by_name['TimeRange'] -Extension = _reflection.GeneratedProtocolMessageType('Extension', (_message.Message,), { - 'DESCRIPTOR' : _EXTENSION, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.Extension) - }) -_sym_db.RegisterMessage(Extension) - -RegisteredExtension = _reflection.GeneratedProtocolMessageType('RegisteredExtension', (_message.Message,), { - 'DESCRIPTOR' : _REGISTEREDEXTENSION, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.RegisteredExtension) - }) -_sym_db.RegisterMessage(RegisteredExtension) - -MasterArbitration = _reflection.GeneratedProtocolMessageType('MasterArbitration', (_message.Message,), { - 'DESCRIPTOR' : _MASTERARBITRATION, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.MasterArbitration) - }) -_sym_db.RegisterMessage(MasterArbitration) - -Uint128 = _reflection.GeneratedProtocolMessageType('Uint128', (_message.Message,), { - 'DESCRIPTOR' : _UINT128, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.Uint128) - }) -_sym_db.RegisterMessage(Uint128) - -Role = _reflection.GeneratedProtocolMessageType('Role', (_message.Message,), { - 'DESCRIPTOR' : _ROLE, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.Role) - }) -_sym_db.RegisterMessage(Role) - -History = _reflection.GeneratedProtocolMessageType('History', (_message.Message,), { - 'DESCRIPTOR' : _HISTORY, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.History) - }) -_sym_db.RegisterMessage(History) - -TimeRange = _reflection.GeneratedProtocolMessageType('TimeRange', (_message.Message,), { - 'DESCRIPTOR' : _TIMERANGE, - '__module__' : 'gnmi_ext_pb2' - # @@protoc_insertion_point(class_scope:gnmi_ext.TimeRange) - }) -_sym_db.RegisterMessage(TimeRange) - -if _descriptor._USE_C_DESCRIPTORS == False: - - DESCRIPTOR._options = None - DESCRIPTOR._serialized_options = b'Z)github.com/openconfig/gnmi/proto/gnmi_ext' - _EXTENSIONID._serialized_start=549 - _EXTENSIONID._serialized_end=600 - _EXTENSION._serialized_start=29 - _EXTENSION._serialized_end=201 - _REGISTEREDEXTENSION._serialized_start=203 - _REGISTEREDEXTENSION._serialized_end=272 - _MASTERARBITRATION._serialized_start=274 - _MASTERARBITRATION._serialized_end=363 - _UINT128._serialized_start=365 - _UINT128._serialized_end=401 - _ROLE._serialized_start=403 - _ROLE._serialized_end=421 - _HISTORY._serialized_start=423 - _HISTORY._serialized_end=506 - _TIMERANGE._serialized_start=508 - _TIMERANGE._serialized_end=547 -# @@protoc_insertion_point(module_scope) \ No newline at end of file +from google.protobuf import duration_pb2 as google_dot_protobuf_dot_duration__pb2 + + +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x0egnmi_ext.proto\x12\x08gnmi_ext\x1a\x1egoogle/protobuf/duration.proto\"\xf2\x01\n\tExtension\x12\x37\n\x0eregistered_ext\x18\x01 \x01(\x0b\x32\x1d.gnmi_ext.RegisteredExtensionH\x00\x12\x39\n\x12master_arbitration\x18\x02 \x01(\x0b\x32\x1b.gnmi_ext.MasterArbitrationH\x00\x12$\n\x07history\x18\x03 \x01(\x0b\x32\x11.gnmi_ext.HistoryH\x00\x12\"\n\x06\x63ommit\x18\x04 \x01(\x0b\x32\x10.gnmi_ext.CommitH\x00\x12 \n\x05\x64\x65pth\x18\x05 \x01(\x0b\x32\x0f.gnmi_ext.DepthH\x00\x42\x05\n\x03\x65xt\"E\n\x13RegisteredExtension\x12!\n\x02id\x18\x01 \x01(\x0e\x32\x15.gnmi_ext.ExtensionID\x12\x0b\n\x03msg\x18\x02 \x01(\x0c\"Y\n\x11MasterArbitration\x12\x1c\n\x04role\x18\x01 \x01(\x0b\x32\x0e.gnmi_ext.Role\x12&\n\x0b\x65lection_id\x18\x02 \x01(\x0b\x32\x11.gnmi_ext.Uint128\"$\n\x07Uint128\x12\x0c\n\x04high\x18\x01 \x01(\x04\x12\x0b\n\x03low\x18\x02 \x01(\x04\"\x12\n\x04Role\x12\n\n\x02id\x18\x01 \x01(\t\"S\n\x07History\x12\x17\n\rsnapshot_time\x18\x01 \x01(\x03H\x00\x12$\n\x05range\x18\x02 \x01(\x0b\x32\x13.gnmi_ext.TimeRangeH\x00\x42\t\n\x07request\"\'\n\tTimeRange\x12\r\n\x05start\x18\x01 \x01(\x03\x12\x0b\n\x03\x65nd\x18\x02 \x01(\x03\"\xe5\x01\n\x06\x43ommit\x12\n\n\x02id\x18\x01 \x01(\t\x12)\n\x06\x63ommit\x18\x02 \x01(\x0b\x32\x17.gnmi_ext.CommitRequestH\x00\x12*\n\x07\x63onfirm\x18\x03 \x01(\x0b\x32\x17.gnmi_ext.CommitConfirmH\x00\x12(\n\x06\x63\x61ncel\x18\x04 \x01(\x0b\x32\x16.gnmi_ext.CommitCancelH\x00\x12\x44\n\x15set_rollback_duration\x18\x05 \x01(\x0b\x32#.gnmi_ext.CommitSetRollbackDurationH\x00\x42\x08\n\x06\x61\x63tion\"E\n\rCommitRequest\x12\x34\n\x11rollback_duration\x18\x01 \x01(\x0b\x32\x19.google.protobuf.Duration\"\x0f\n\rCommitConfirm\"\x0e\n\x0c\x43ommitCancel\"Q\n\x19\x43ommitSetRollbackDuration\x12\x34\n\x11rollback_duration\x18\x01 \x01(\x0b\x32\x19.google.protobuf.Duration\"\x16\n\x05\x44\x65pth\x12\r\n\x05level\x18\x01 \x01(\r*3\n\x0b\x45xtensionID\x12\r\n\tEID_UNSET\x10\x00\x12\x15\n\x10\x45ID_EXPERIMENTAL\x10\xe7\x07\x42+Z)github.com/openconfig/gnmi/proto/gnmi_extb\x06proto3') + +_globals = globals() +_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) +_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'gnmi_ext_pb2', _globals) +if not _descriptor._USE_C_DESCRIPTORS: + _globals['DESCRIPTOR']._loaded_options = None + _globals['DESCRIPTOR']._serialized_options = b'Z)github.com/openconfig/gnmi/proto/gnmi_ext' + _globals['_EXTENSIONID']._serialized_start=1094 + _globals['_EXTENSIONID']._serialized_end=1145 + _globals['_EXTENSION']._serialized_start=61 + _globals['_EXTENSION']._serialized_end=303 + _globals['_REGISTEREDEXTENSION']._serialized_start=305 + _globals['_REGISTEREDEXTENSION']._serialized_end=374 + _globals['_MASTERARBITRATION']._serialized_start=376 + _globals['_MASTERARBITRATION']._serialized_end=465 + _globals['_UINT128']._serialized_start=467 + _globals['_UINT128']._serialized_end=503 + _globals['_ROLE']._serialized_start=505 + _globals['_ROLE']._serialized_end=523 + _globals['_HISTORY']._serialized_start=525 + _globals['_HISTORY']._serialized_end=608 + _globals['_TIMERANGE']._serialized_start=610 + _globals['_TIMERANGE']._serialized_end=649 + _globals['_COMMIT']._serialized_start=652 + _globals['_COMMIT']._serialized_end=881 + _globals['_COMMITREQUEST']._serialized_start=883 + _globals['_COMMITREQUEST']._serialized_end=952 + _globals['_COMMITCONFIRM']._serialized_start=954 + _globals['_COMMITCONFIRM']._serialized_end=969 + _globals['_COMMITCANCEL']._serialized_start=971 + _globals['_COMMITCANCEL']._serialized_end=985 + _globals['_COMMITSETROLLBACKDURATION']._serialized_start=987 + _globals['_COMMITSETROLLBACKDURATION']._serialized_end=1068 + _globals['_DEPTH']._serialized_start=1070 + _globals['_DEPTH']._serialized_end=1092 +# @@protoc_insertion_point(module_scope) diff --git a/connector/src/yang/connector/proto/gnmi_ext_pb2_grpc.py b/connector/src/yang/connector/proto/gnmi_ext_pb2_grpc.py index 8a939394..cde64138 100644 --- a/connector/src/yang/connector/proto/gnmi_ext_pb2_grpc.py +++ b/connector/src/yang/connector/proto/gnmi_ext_pb2_grpc.py @@ -1,3 +1,24 @@ # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT! """Client and server classes corresponding to protobuf-defined services.""" import grpc +import warnings + + +GRPC_GENERATED_VERSION = '1.67.1' +GRPC_VERSION = grpc.__version__ +_version_not_supported = False + +try: + from grpc._utilities import first_version_is_lower + _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION) +except ImportError: + _version_not_supported = True + +if _version_not_supported: + raise RuntimeError( + f'The grpc package installed is at version {GRPC_VERSION},' + + f' but the generated code in gnmi_ext_pb2_grpc.py depends on' + + f' grpcio>={GRPC_GENERATED_VERSION}.' + + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}' + + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.' + ) diff --git a/connector/src/yang/connector/proto/gnmi_pb2.py b/connector/src/yang/connector/proto/gnmi_pb2.py index e7542008..572a3ee2 100644 --- a/connector/src/yang/connector/proto/gnmi_pb2.py +++ b/connector/src/yang/connector/proto/gnmi_pb2.py @@ -1,13 +1,22 @@ # -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! +# NO CHECKED-IN PROTOBUF GENCODE # source: gnmi.proto +# Protobuf Python Version: 5.27.2 """Generated protocol buffer code.""" -from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import descriptor_pool as _descriptor_pool -from google.protobuf import message as _message -from google.protobuf import reflection as _reflection +from google.protobuf import runtime_version as _runtime_version from google.protobuf import symbol_database as _symbol_database +from google.protobuf.internal import builder as _builder +_runtime_version.ValidateProtobufRuntimeVersion( + _runtime_version.Domain.PUBLIC, + 5, + 27, + 2, + '', + 'gnmi.proto' +) # @@protoc_insertion_point(imports) _sym_db = _symbol_database.Default() @@ -20,308 +29,96 @@ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\ngnmi.proto\x12\x04gnmi\x1a\x19google/protobuf/any.proto\x1a google/protobuf/descriptor.proto\x1a\x0egnmi_ext.proto\"\x94\x01\n\x0cNotification\x12\x11\n\ttimestamp\x18\x01 \x01(\x03\x12\x1a\n\x06prefix\x18\x02 \x01(\x0b\x32\n.gnmi.Path\x12\x1c\n\x06update\x18\x04 \x03(\x0b\x32\x0c.gnmi.Update\x12\x1a\n\x06\x64\x65lete\x18\x05 \x03(\x0b\x32\n.gnmi.Path\x12\x0e\n\x06\x61tomic\x18\x06 \x01(\x08J\x04\x08\x03\x10\x04R\x05\x61lias\"u\n\x06Update\x12\x18\n\x04path\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12\x1e\n\x05value\x18\x02 \x01(\x0b\x32\x0b.gnmi.ValueB\x02\x18\x01\x12\x1d\n\x03val\x18\x03 \x01(\x0b\x32\x10.gnmi.TypedValue\x12\x12\n\nduplicates\x18\x04 \x01(\r\"\x83\x03\n\nTypedValue\x12\x14\n\nstring_val\x18\x01 \x01(\tH\x00\x12\x11\n\x07int_val\x18\x02 \x01(\x03H\x00\x12\x12\n\x08uint_val\x18\x03 \x01(\x04H\x00\x12\x12\n\x08\x62ool_val\x18\x04 \x01(\x08H\x00\x12\x13\n\tbytes_val\x18\x05 \x01(\x0cH\x00\x12\x17\n\tfloat_val\x18\x06 \x01(\x02\x42\x02\x18\x01H\x00\x12\x14\n\ndouble_val\x18\x0e \x01(\x01H\x00\x12*\n\x0b\x64\x65\x63imal_val\x18\x07 \x01(\x0b\x32\x0f.gnmi.Decimal64B\x02\x18\x01H\x00\x12)\n\x0cleaflist_val\x18\x08 \x01(\x0b\x32\x11.gnmi.ScalarArrayH\x00\x12\'\n\x07\x61ny_val\x18\t \x01(\x0b\x32\x14.google.protobuf.AnyH\x00\x12\x12\n\x08json_val\x18\n \x01(\x0cH\x00\x12\x17\n\rjson_ietf_val\x18\x0b \x01(\x0cH\x00\x12\x13\n\tascii_val\x18\x0c \x01(\tH\x00\x12\x15\n\x0bproto_bytes\x18\r \x01(\x0cH\x00\x42\x07\n\x05value\"Y\n\x04Path\x12\x13\n\x07\x65lement\x18\x01 \x03(\tB\x02\x18\x01\x12\x0e\n\x06origin\x18\x02 \x01(\t\x12\x1c\n\x04\x65lem\x18\x03 \x03(\x0b\x32\x0e.gnmi.PathElem\x12\x0e\n\x06target\x18\x04 \x01(\t\"j\n\x08PathElem\x12\x0c\n\x04name\x18\x01 \x01(\t\x12$\n\x03key\x18\x02 \x03(\x0b\x32\x17.gnmi.PathElem.KeyEntry\x1a*\n\x08KeyEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"8\n\x05Value\x12\r\n\x05value\x18\x01 \x01(\x0c\x12\x1c\n\x04type\x18\x02 \x01(\x0e\x32\x0e.gnmi.Encoding:\x02\x18\x01\"N\n\x05\x45rror\x12\x0c\n\x04\x63ode\x18\x01 \x01(\r\x12\x0f\n\x07message\x18\x02 \x01(\t\x12\"\n\x04\x64\x61ta\x18\x03 \x01(\x0b\x32\x14.google.protobuf.Any:\x02\x18\x01\"2\n\tDecimal64\x12\x0e\n\x06\x64igits\x18\x01 \x01(\x03\x12\x11\n\tprecision\x18\x02 \x01(\r:\x02\x18\x01\"0\n\x0bScalarArray\x12!\n\x07\x65lement\x18\x01 \x03(\x0b\x32\x10.gnmi.TypedValue\"\x9d\x01\n\x10SubscribeRequest\x12+\n\tsubscribe\x18\x01 \x01(\x0b\x32\x16.gnmi.SubscriptionListH\x00\x12\x1a\n\x04poll\x18\x03 \x01(\x0b\x32\n.gnmi.PollH\x00\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.ExtensionB\t\n\x07requestJ\x04\x08\x04\x10\x05R\x07\x61liases\"\x06\n\x04Poll\"\xa8\x01\n\x11SubscribeResponse\x12$\n\x06update\x18\x01 \x01(\x0b\x32\x12.gnmi.NotificationH\x00\x12\x17\n\rsync_response\x18\x03 \x01(\x08H\x00\x12 \n\x05\x65rror\x18\x04 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01H\x00\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.ExtensionB\n\n\x08response\"\xd5\x02\n\x10SubscriptionList\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12(\n\x0csubscription\x18\x02 \x03(\x0b\x32\x12.gnmi.Subscription\x12\x1d\n\x03qos\x18\x04 \x01(\x0b\x32\x10.gnmi.QOSMarking\x12)\n\x04mode\x18\x05 \x01(\x0e\x32\x1b.gnmi.SubscriptionList.Mode\x12\x19\n\x11\x61llow_aggregation\x18\x06 \x01(\x08\x12#\n\nuse_models\x18\x07 \x03(\x0b\x32\x0f.gnmi.ModelData\x12 \n\x08\x65ncoding\x18\x08 \x01(\x0e\x32\x0e.gnmi.Encoding\x12\x14\n\x0cupdates_only\x18\t \x01(\x08\"&\n\x04Mode\x12\n\n\x06STREAM\x10\x00\x12\x08\n\x04ONCE\x10\x01\x12\x08\n\x04POLL\x10\x02J\x04\x08\x03\x10\x04R\x0buse_aliases\"\x9f\x01\n\x0cSubscription\x12\x18\n\x04path\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12$\n\x04mode\x18\x02 \x01(\x0e\x32\x16.gnmi.SubscriptionMode\x12\x17\n\x0fsample_interval\x18\x03 \x01(\x04\x12\x1a\n\x12suppress_redundant\x18\x04 \x01(\x08\x12\x1a\n\x12heartbeat_interval\x18\x05 \x01(\x04\"\x1d\n\nQOSMarking\x12\x0f\n\x07marking\x18\x01 \x01(\r\"\xce\x01\n\nSetRequest\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12\x1a\n\x06\x64\x65lete\x18\x02 \x03(\x0b\x32\n.gnmi.Path\x12\x1d\n\x07replace\x18\x03 \x03(\x0b\x32\x0c.gnmi.Update\x12\x1c\n\x06update\x18\x04 \x03(\x0b\x32\x0c.gnmi.Update\x12#\n\runion_replace\x18\x06 \x03(\x0b\x32\x0c.gnmi.Update\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.Extension\"\xac\x01\n\x0bSetResponse\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12$\n\x08response\x18\x02 \x03(\x0b\x32\x12.gnmi.UpdateResult\x12 \n\x07message\x18\x03 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01\x12\x11\n\ttimestamp\x18\x04 \x01(\x03\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.Extension\"\xdd\x01\n\x0cUpdateResult\x12\x15\n\ttimestamp\x18\x01 \x01(\x03\x42\x02\x18\x01\x12\x18\n\x04path\x18\x02 \x01(\x0b\x32\n.gnmi.Path\x12 \n\x07message\x18\x03 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01\x12(\n\x02op\x18\x04 \x01(\x0e\x32\x1c.gnmi.UpdateResult.Operation\"P\n\tOperation\x12\x0b\n\x07INVALID\x10\x00\x12\n\n\x06\x44\x45LETE\x10\x01\x12\x0b\n\x07REPLACE\x10\x02\x12\n\n\x06UPDATE\x10\x03\x12\x11\n\rUNION_REPLACE\x10\x04\"\x97\x02\n\nGetRequest\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12\x18\n\x04path\x18\x02 \x03(\x0b\x32\n.gnmi.Path\x12\'\n\x04type\x18\x03 \x01(\x0e\x32\x19.gnmi.GetRequest.DataType\x12 \n\x08\x65ncoding\x18\x05 \x01(\x0e\x32\x0e.gnmi.Encoding\x12#\n\nuse_models\x18\x06 \x03(\x0b\x32\x0f.gnmi.ModelData\x12&\n\textension\x18\x07 \x03(\x0b\x32\x13.gnmi_ext.Extension\";\n\x08\x44\x61taType\x12\x07\n\x03\x41LL\x10\x00\x12\n\n\x06\x43ONFIG\x10\x01\x12\t\n\x05STATE\x10\x02\x12\x0f\n\x0bOPERATIONAL\x10\x03\"\x7f\n\x0bGetResponse\x12(\n\x0cnotification\x18\x01 \x03(\x0b\x32\x12.gnmi.Notification\x12\x1e\n\x05\x65rror\x18\x02 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01\x12&\n\textension\x18\x03 \x03(\x0b\x32\x13.gnmi_ext.Extension\";\n\x11\x43\x61pabilityRequest\x12&\n\textension\x18\x01 \x03(\x0b\x32\x13.gnmi_ext.Extension\"\xaa\x01\n\x12\x43\x61pabilityResponse\x12)\n\x10supported_models\x18\x01 \x03(\x0b\x32\x0f.gnmi.ModelData\x12+\n\x13supported_encodings\x18\x02 \x03(\x0e\x32\x0e.gnmi.Encoding\x12\x14\n\x0cgNMI_version\x18\x03 \x01(\t\x12&\n\textension\x18\x04 \x03(\x0b\x32\x13.gnmi_ext.Extension\"@\n\tModelData\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0corganization\x18\x02 \x01(\t\x12\x0f\n\x07version\x18\x03 \x01(\t*D\n\x08\x45ncoding\x12\x08\n\x04JSON\x10\x00\x12\t\n\x05\x42YTES\x10\x01\x12\t\n\x05PROTO\x10\x02\x12\t\n\x05\x41SCII\x10\x03\x12\r\n\tJSON_IETF\x10\x04*A\n\x10SubscriptionMode\x12\x12\n\x0eTARGET_DEFINED\x10\x00\x12\r\n\tON_CHANGE\x10\x01\x12\n\n\x06SAMPLE\x10\x02\x32\xe3\x01\n\x04gNMI\x12\x41\n\x0c\x43\x61pabilities\x12\x17.gnmi.CapabilityRequest\x1a\x18.gnmi.CapabilityResponse\x12*\n\x03Get\x12\x10.gnmi.GetRequest\x1a\x11.gnmi.GetResponse\x12*\n\x03Set\x12\x10.gnmi.SetRequest\x1a\x11.gnmi.SetResponse\x12@\n\tSubscribe\x12\x16.gnmi.SubscribeRequest\x1a\x17.gnmi.SubscribeResponse(\x01\x30\x01:3\n\x0cgnmi_service\x12\x1c.google.protobuf.FileOptions\x18\xe9\x07 \x01(\tBT\n\x15\x63om.github.gnmi.protoB\tGnmiProtoP\x01Z%github.com/openconfig/gnmi/proto/gnmi\xca>\x06\x30.10.0b\x06proto3') -_ENCODING = DESCRIPTOR.enum_types_by_name['Encoding'] -Encoding = enum_type_wrapper.EnumTypeWrapper(_ENCODING) -_SUBSCRIPTIONMODE = DESCRIPTOR.enum_types_by_name['SubscriptionMode'] -SubscriptionMode = enum_type_wrapper.EnumTypeWrapper(_SUBSCRIPTIONMODE) -JSON = 0 -BYTES = 1 -PROTO = 2 -ASCII = 3 -JSON_IETF = 4 -TARGET_DEFINED = 0 -ON_CHANGE = 1 -SAMPLE = 2 - -GNMI_SERVICE_FIELD_NUMBER = 1001 -gnmi_service = DESCRIPTOR.extensions_by_name['gnmi_service'] - -_NOTIFICATION = DESCRIPTOR.message_types_by_name['Notification'] -_UPDATE = DESCRIPTOR.message_types_by_name['Update'] -_TYPEDVALUE = DESCRIPTOR.message_types_by_name['TypedValue'] -_PATH = DESCRIPTOR.message_types_by_name['Path'] -_PATHELEM = DESCRIPTOR.message_types_by_name['PathElem'] -_PATHELEM_KEYENTRY = _PATHELEM.nested_types_by_name['KeyEntry'] -_VALUE = DESCRIPTOR.message_types_by_name['Value'] -_ERROR = DESCRIPTOR.message_types_by_name['Error'] -_DECIMAL64 = DESCRIPTOR.message_types_by_name['Decimal64'] -_SCALARARRAY = DESCRIPTOR.message_types_by_name['ScalarArray'] -_SUBSCRIBEREQUEST = DESCRIPTOR.message_types_by_name['SubscribeRequest'] -_POLL = DESCRIPTOR.message_types_by_name['Poll'] -_SUBSCRIBERESPONSE = DESCRIPTOR.message_types_by_name['SubscribeResponse'] -_SUBSCRIPTIONLIST = DESCRIPTOR.message_types_by_name['SubscriptionList'] -_SUBSCRIPTION = DESCRIPTOR.message_types_by_name['Subscription'] -_QOSMARKING = DESCRIPTOR.message_types_by_name['QOSMarking'] -_SETREQUEST = DESCRIPTOR.message_types_by_name['SetRequest'] -_SETRESPONSE = DESCRIPTOR.message_types_by_name['SetResponse'] -_UPDATERESULT = DESCRIPTOR.message_types_by_name['UpdateResult'] -_GETREQUEST = DESCRIPTOR.message_types_by_name['GetRequest'] -_GETRESPONSE = DESCRIPTOR.message_types_by_name['GetResponse'] -_CAPABILITYREQUEST = DESCRIPTOR.message_types_by_name['CapabilityRequest'] -_CAPABILITYRESPONSE = DESCRIPTOR.message_types_by_name['CapabilityResponse'] -_MODELDATA = DESCRIPTOR.message_types_by_name['ModelData'] -_SUBSCRIPTIONLIST_MODE = _SUBSCRIPTIONLIST.enum_types_by_name['Mode'] -_UPDATERESULT_OPERATION = _UPDATERESULT.enum_types_by_name['Operation'] -_GETREQUEST_DATATYPE = _GETREQUEST.enum_types_by_name['DataType'] -Notification = _reflection.GeneratedProtocolMessageType('Notification', (_message.Message,), { - 'DESCRIPTOR' : _NOTIFICATION, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Notification) - }) -_sym_db.RegisterMessage(Notification) - -Update = _reflection.GeneratedProtocolMessageType('Update', (_message.Message,), { - 'DESCRIPTOR' : _UPDATE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Update) - }) -_sym_db.RegisterMessage(Update) - -TypedValue = _reflection.GeneratedProtocolMessageType('TypedValue', (_message.Message,), { - 'DESCRIPTOR' : _TYPEDVALUE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.TypedValue) - }) -_sym_db.RegisterMessage(TypedValue) - -Path = _reflection.GeneratedProtocolMessageType('Path', (_message.Message,), { - 'DESCRIPTOR' : _PATH, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Path) - }) -_sym_db.RegisterMessage(Path) - -PathElem = _reflection.GeneratedProtocolMessageType('PathElem', (_message.Message,), { - - 'KeyEntry' : _reflection.GeneratedProtocolMessageType('KeyEntry', (_message.Message,), { - 'DESCRIPTOR' : _PATHELEM_KEYENTRY, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.PathElem.KeyEntry) - }) - , - 'DESCRIPTOR' : _PATHELEM, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.PathElem) - }) -_sym_db.RegisterMessage(PathElem) -_sym_db.RegisterMessage(PathElem.KeyEntry) - -Value = _reflection.GeneratedProtocolMessageType('Value', (_message.Message,), { - 'DESCRIPTOR' : _VALUE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Value) - }) -_sym_db.RegisterMessage(Value) - -Error = _reflection.GeneratedProtocolMessageType('Error', (_message.Message,), { - 'DESCRIPTOR' : _ERROR, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Error) - }) -_sym_db.RegisterMessage(Error) - -Decimal64 = _reflection.GeneratedProtocolMessageType('Decimal64', (_message.Message,), { - 'DESCRIPTOR' : _DECIMAL64, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Decimal64) - }) -_sym_db.RegisterMessage(Decimal64) - -ScalarArray = _reflection.GeneratedProtocolMessageType('ScalarArray', (_message.Message,), { - 'DESCRIPTOR' : _SCALARARRAY, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.ScalarArray) - }) -_sym_db.RegisterMessage(ScalarArray) - -SubscribeRequest = _reflection.GeneratedProtocolMessageType('SubscribeRequest', (_message.Message,), { - 'DESCRIPTOR' : _SUBSCRIBEREQUEST, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.SubscribeRequest) - }) -_sym_db.RegisterMessage(SubscribeRequest) - -Poll = _reflection.GeneratedProtocolMessageType('Poll', (_message.Message,), { - 'DESCRIPTOR' : _POLL, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Poll) - }) -_sym_db.RegisterMessage(Poll) - -SubscribeResponse = _reflection.GeneratedProtocolMessageType('SubscribeResponse', (_message.Message,), { - 'DESCRIPTOR' : _SUBSCRIBERESPONSE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.SubscribeResponse) - }) -_sym_db.RegisterMessage(SubscribeResponse) - -SubscriptionList = _reflection.GeneratedProtocolMessageType('SubscriptionList', (_message.Message,), { - 'DESCRIPTOR' : _SUBSCRIPTIONLIST, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.SubscriptionList) - }) -_sym_db.RegisterMessage(SubscriptionList) - -Subscription = _reflection.GeneratedProtocolMessageType('Subscription', (_message.Message,), { - 'DESCRIPTOR' : _SUBSCRIPTION, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.Subscription) - }) -_sym_db.RegisterMessage(Subscription) - -QOSMarking = _reflection.GeneratedProtocolMessageType('QOSMarking', (_message.Message,), { - 'DESCRIPTOR' : _QOSMARKING, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.QOSMarking) - }) -_sym_db.RegisterMessage(QOSMarking) - -SetRequest = _reflection.GeneratedProtocolMessageType('SetRequest', (_message.Message,), { - 'DESCRIPTOR' : _SETREQUEST, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.SetRequest) - }) -_sym_db.RegisterMessage(SetRequest) - -SetResponse = _reflection.GeneratedProtocolMessageType('SetResponse', (_message.Message,), { - 'DESCRIPTOR' : _SETRESPONSE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.SetResponse) - }) -_sym_db.RegisterMessage(SetResponse) - -UpdateResult = _reflection.GeneratedProtocolMessageType('UpdateResult', (_message.Message,), { - 'DESCRIPTOR' : _UPDATERESULT, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.UpdateResult) - }) -_sym_db.RegisterMessage(UpdateResult) - -GetRequest = _reflection.GeneratedProtocolMessageType('GetRequest', (_message.Message,), { - 'DESCRIPTOR' : _GETREQUEST, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.GetRequest) - }) -_sym_db.RegisterMessage(GetRequest) - -GetResponse = _reflection.GeneratedProtocolMessageType('GetResponse', (_message.Message,), { - 'DESCRIPTOR' : _GETRESPONSE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.GetResponse) - }) -_sym_db.RegisterMessage(GetResponse) - -CapabilityRequest = _reflection.GeneratedProtocolMessageType('CapabilityRequest', (_message.Message,), { - 'DESCRIPTOR' : _CAPABILITYREQUEST, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.CapabilityRequest) - }) -_sym_db.RegisterMessage(CapabilityRequest) - -CapabilityResponse = _reflection.GeneratedProtocolMessageType('CapabilityResponse', (_message.Message,), { - 'DESCRIPTOR' : _CAPABILITYRESPONSE, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.CapabilityResponse) - }) -_sym_db.RegisterMessage(CapabilityResponse) - -ModelData = _reflection.GeneratedProtocolMessageType('ModelData', (_message.Message,), { - 'DESCRIPTOR' : _MODELDATA, - '__module__' : 'gnmi_pb2' - # @@protoc_insertion_point(class_scope:gnmi.ModelData) - }) -_sym_db.RegisterMessage(ModelData) - -_GNMI = DESCRIPTOR.services_by_name['gNMI'] -if _descriptor._USE_C_DESCRIPTORS == False: - google_dot_protobuf_dot_descriptor__pb2.FileOptions.RegisterExtension(gnmi_service) - - DESCRIPTOR._options = None - DESCRIPTOR._serialized_options = b'\n\025com.github.gnmi.protoB\tGnmiProtoP\001Z%github.com/openconfig/gnmi/proto/gnmi\312>\0060.10.0' - _UPDATE.fields_by_name['value']._options = None - _UPDATE.fields_by_name['value']._serialized_options = b'\030\001' - _TYPEDVALUE.fields_by_name['float_val']._options = None - _TYPEDVALUE.fields_by_name['float_val']._serialized_options = b'\030\001' - _TYPEDVALUE.fields_by_name['decimal_val']._options = None - _TYPEDVALUE.fields_by_name['decimal_val']._serialized_options = b'\030\001' - _PATH.fields_by_name['element']._options = None - _PATH.fields_by_name['element']._serialized_options = b'\030\001' - _PATHELEM_KEYENTRY._options = None - _PATHELEM_KEYENTRY._serialized_options = b'8\001' - _VALUE._options = None - _VALUE._serialized_options = b'\030\001' - _ERROR._options = None - _ERROR._serialized_options = b'\030\001' - _DECIMAL64._options = None - _DECIMAL64._serialized_options = b'\030\001' - _SUBSCRIBERESPONSE.fields_by_name['error']._options = None - _SUBSCRIBERESPONSE.fields_by_name['error']._serialized_options = b'\030\001' - _SETRESPONSE.fields_by_name['message']._options = None - _SETRESPONSE.fields_by_name['message']._serialized_options = b'\030\001' - _UPDATERESULT.fields_by_name['timestamp']._options = None - _UPDATERESULT.fields_by_name['timestamp']._serialized_options = b'\030\001' - _UPDATERESULT.fields_by_name['message']._options = None - _UPDATERESULT.fields_by_name['message']._serialized_options = b'\030\001' - _GETRESPONSE.fields_by_name['error']._options = None - _GETRESPONSE.fields_by_name['error']._serialized_options = b'\030\001' - _ENCODING._serialized_start=3391 - _ENCODING._serialized_end=3459 - _SUBSCRIPTIONMODE._serialized_start=3461 - _SUBSCRIPTIONMODE._serialized_end=3526 - _NOTIFICATION._serialized_start=98 - _NOTIFICATION._serialized_end=246 - _UPDATE._serialized_start=248 - _UPDATE._serialized_end=365 - _TYPEDVALUE._serialized_start=368 - _TYPEDVALUE._serialized_end=755 - _PATH._serialized_start=757 - _PATH._serialized_end=846 - _PATHELEM._serialized_start=848 - _PATHELEM._serialized_end=954 - _PATHELEM_KEYENTRY._serialized_start=912 - _PATHELEM_KEYENTRY._serialized_end=954 - _VALUE._serialized_start=956 - _VALUE._serialized_end=1012 - _ERROR._serialized_start=1014 - _ERROR._serialized_end=1092 - _DECIMAL64._serialized_start=1094 - _DECIMAL64._serialized_end=1144 - _SCALARARRAY._serialized_start=1146 - _SCALARARRAY._serialized_end=1194 - _SUBSCRIBEREQUEST._serialized_start=1197 - _SUBSCRIBEREQUEST._serialized_end=1354 - _POLL._serialized_start=1356 - _POLL._serialized_end=1362 - _SUBSCRIBERESPONSE._serialized_start=1365 - _SUBSCRIBERESPONSE._serialized_end=1533 - _SUBSCRIPTIONLIST._serialized_start=1536 - _SUBSCRIPTIONLIST._serialized_end=1877 - _SUBSCRIPTIONLIST_MODE._serialized_start=1820 - _SUBSCRIPTIONLIST_MODE._serialized_end=1858 - _SUBSCRIPTION._serialized_start=1880 - _SUBSCRIPTION._serialized_end=2039 - _QOSMARKING._serialized_start=2041 - _QOSMARKING._serialized_end=2070 - _SETREQUEST._serialized_start=2073 - _SETREQUEST._serialized_end=2279 - _SETRESPONSE._serialized_start=2282 - _SETRESPONSE._serialized_end=2454 - _UPDATERESULT._serialized_start=2457 - _UPDATERESULT._serialized_end=2678 - _UPDATERESULT_OPERATION._serialized_start=2598 - _UPDATERESULT_OPERATION._serialized_end=2678 - _GETREQUEST._serialized_start=2681 - _GETREQUEST._serialized_end=2960 - _GETREQUEST_DATATYPE._serialized_start=2901 - _GETREQUEST_DATATYPE._serialized_end=2960 - _GETRESPONSE._serialized_start=2962 - _GETRESPONSE._serialized_end=3089 - _CAPABILITYREQUEST._serialized_start=3091 - _CAPABILITYREQUEST._serialized_end=3150 - _CAPABILITYRESPONSE._serialized_start=3153 - _CAPABILITYRESPONSE._serialized_end=3323 - _MODELDATA._serialized_start=3325 - _MODELDATA._serialized_end=3389 - _GNMI._serialized_start=3529 - _GNMI._serialized_end=3756 -# @@protoc_insertion_point(module_scope) \ No newline at end of file +_globals = globals() +_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) +_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'gnmi_pb2', _globals) +if not _descriptor._USE_C_DESCRIPTORS: + _globals['DESCRIPTOR']._loaded_options = None + _globals['DESCRIPTOR']._serialized_options = b'\n\025com.github.gnmi.protoB\tGnmiProtoP\001Z%github.com/openconfig/gnmi/proto/gnmi\312>\0060.10.0' + _globals['_UPDATE'].fields_by_name['value']._loaded_options = None + _globals['_UPDATE'].fields_by_name['value']._serialized_options = b'\030\001' + _globals['_TYPEDVALUE'].fields_by_name['float_val']._loaded_options = None + _globals['_TYPEDVALUE'].fields_by_name['float_val']._serialized_options = b'\030\001' + _globals['_TYPEDVALUE'].fields_by_name['decimal_val']._loaded_options = None + _globals['_TYPEDVALUE'].fields_by_name['decimal_val']._serialized_options = b'\030\001' + _globals['_PATH'].fields_by_name['element']._loaded_options = None + _globals['_PATH'].fields_by_name['element']._serialized_options = b'\030\001' + _globals['_PATHELEM_KEYENTRY']._loaded_options = None + _globals['_PATHELEM_KEYENTRY']._serialized_options = b'8\001' + _globals['_VALUE']._loaded_options = None + _globals['_VALUE']._serialized_options = b'\030\001' + _globals['_ERROR']._loaded_options = None + _globals['_ERROR']._serialized_options = b'\030\001' + _globals['_DECIMAL64']._loaded_options = None + _globals['_DECIMAL64']._serialized_options = b'\030\001' + _globals['_SUBSCRIBERESPONSE'].fields_by_name['error']._loaded_options = None + _globals['_SUBSCRIBERESPONSE'].fields_by_name['error']._serialized_options = b'\030\001' + _globals['_SETRESPONSE'].fields_by_name['message']._loaded_options = None + _globals['_SETRESPONSE'].fields_by_name['message']._serialized_options = b'\030\001' + _globals['_UPDATERESULT'].fields_by_name['timestamp']._loaded_options = None + _globals['_UPDATERESULT'].fields_by_name['timestamp']._serialized_options = b'\030\001' + _globals['_UPDATERESULT'].fields_by_name['message']._loaded_options = None + _globals['_UPDATERESULT'].fields_by_name['message']._serialized_options = b'\030\001' + _globals['_GETRESPONSE'].fields_by_name['error']._loaded_options = None + _globals['_GETRESPONSE'].fields_by_name['error']._serialized_options = b'\030\001' + _globals['_ENCODING']._serialized_start=3391 + _globals['_ENCODING']._serialized_end=3459 + _globals['_SUBSCRIPTIONMODE']._serialized_start=3461 + _globals['_SUBSCRIPTIONMODE']._serialized_end=3526 + _globals['_NOTIFICATION']._serialized_start=98 + _globals['_NOTIFICATION']._serialized_end=246 + _globals['_UPDATE']._serialized_start=248 + _globals['_UPDATE']._serialized_end=365 + _globals['_TYPEDVALUE']._serialized_start=368 + _globals['_TYPEDVALUE']._serialized_end=755 + _globals['_PATH']._serialized_start=757 + _globals['_PATH']._serialized_end=846 + _globals['_PATHELEM']._serialized_start=848 + _globals['_PATHELEM']._serialized_end=954 + _globals['_PATHELEM_KEYENTRY']._serialized_start=912 + _globals['_PATHELEM_KEYENTRY']._serialized_end=954 + _globals['_VALUE']._serialized_start=956 + _globals['_VALUE']._serialized_end=1012 + _globals['_ERROR']._serialized_start=1014 + _globals['_ERROR']._serialized_end=1092 + _globals['_DECIMAL64']._serialized_start=1094 + _globals['_DECIMAL64']._serialized_end=1144 + _globals['_SCALARARRAY']._serialized_start=1146 + _globals['_SCALARARRAY']._serialized_end=1194 + _globals['_SUBSCRIBEREQUEST']._serialized_start=1197 + _globals['_SUBSCRIBEREQUEST']._serialized_end=1354 + _globals['_POLL']._serialized_start=1356 + _globals['_POLL']._serialized_end=1362 + _globals['_SUBSCRIBERESPONSE']._serialized_start=1365 + _globals['_SUBSCRIBERESPONSE']._serialized_end=1533 + _globals['_SUBSCRIPTIONLIST']._serialized_start=1536 + _globals['_SUBSCRIPTIONLIST']._serialized_end=1877 + _globals['_SUBSCRIPTIONLIST_MODE']._serialized_start=1820 + _globals['_SUBSCRIPTIONLIST_MODE']._serialized_end=1858 + _globals['_SUBSCRIPTION']._serialized_start=1880 + _globals['_SUBSCRIPTION']._serialized_end=2039 + _globals['_QOSMARKING']._serialized_start=2041 + _globals['_QOSMARKING']._serialized_end=2070 + _globals['_SETREQUEST']._serialized_start=2073 + _globals['_SETREQUEST']._serialized_end=2279 + _globals['_SETRESPONSE']._serialized_start=2282 + _globals['_SETRESPONSE']._serialized_end=2454 + _globals['_UPDATERESULT']._serialized_start=2457 + _globals['_UPDATERESULT']._serialized_end=2678 + _globals['_UPDATERESULT_OPERATION']._serialized_start=2598 + _globals['_UPDATERESULT_OPERATION']._serialized_end=2678 + _globals['_GETREQUEST']._serialized_start=2681 + _globals['_GETREQUEST']._serialized_end=2960 + _globals['_GETREQUEST_DATATYPE']._serialized_start=2901 + _globals['_GETREQUEST_DATATYPE']._serialized_end=2960 + _globals['_GETRESPONSE']._serialized_start=2962 + _globals['_GETRESPONSE']._serialized_end=3089 + _globals['_CAPABILITYREQUEST']._serialized_start=3091 + _globals['_CAPABILITYREQUEST']._serialized_end=3150 + _globals['_CAPABILITYRESPONSE']._serialized_start=3153 + _globals['_CAPABILITYRESPONSE']._serialized_end=3323 + _globals['_MODELDATA']._serialized_start=3325 + _globals['_MODELDATA']._serialized_end=3389 + _globals['_GNMI']._serialized_start=3529 + _globals['_GNMI']._serialized_end=3756 +# @@protoc_insertion_point(module_scope) diff --git a/connector/src/yang/connector/proto/gnmi_pb2_grpc.py b/connector/src/yang/connector/proto/gnmi_pb2_grpc.py index d725c032..0b4b84e1 100644 --- a/connector/src/yang/connector/proto/gnmi_pb2_grpc.py +++ b/connector/src/yang/connector/proto/gnmi_pb2_grpc.py @@ -1,9 +1,29 @@ # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT! """Client and server classes corresponding to protobuf-defined services.""" import grpc +import warnings from . import gnmi_pb2 as gnmi__pb2 +GRPC_GENERATED_VERSION = '1.67.1' +GRPC_VERSION = grpc.__version__ +_version_not_supported = False + +try: + from grpc._utilities import first_version_is_lower + _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION) +except ImportError: + _version_not_supported = True + +if _version_not_supported: + raise RuntimeError( + f'The grpc package installed is at version {GRPC_VERSION},' + + f' but the generated code in gnmi_pb2_grpc.py depends on' + + f' grpcio>={GRPC_GENERATED_VERSION}.' + + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}' + + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.' + ) + class gNMIStub(object): """Missing associated documentation comment in .proto file.""" @@ -18,22 +38,22 @@ def __init__(self, channel): '/gnmi.gNMI/Capabilities', request_serializer=gnmi__pb2.CapabilityRequest.SerializeToString, response_deserializer=gnmi__pb2.CapabilityResponse.FromString, - ) + _registered_method=True) self.Get = channel.unary_unary( '/gnmi.gNMI/Get', request_serializer=gnmi__pb2.GetRequest.SerializeToString, response_deserializer=gnmi__pb2.GetResponse.FromString, - ) + _registered_method=True) self.Set = channel.unary_unary( '/gnmi.gNMI/Set', request_serializer=gnmi__pb2.SetRequest.SerializeToString, response_deserializer=gnmi__pb2.SetResponse.FromString, - ) + _registered_method=True) self.Subscribe = channel.stream_stream( '/gnmi.gNMI/Subscribe', request_serializer=gnmi__pb2.SubscribeRequest.SerializeToString, response_deserializer=gnmi__pb2.SubscribeResponse.FromString, - ) + _registered_method=True) class gNMIServicer(object): @@ -110,6 +130,7 @@ def add_gNMIServicer_to_server(servicer, server): generic_handler = grpc.method_handlers_generic_handler( 'gnmi.gNMI', rpc_method_handlers) server.add_generic_rpc_handlers((generic_handler,)) + server.add_registered_method_handlers('gnmi.gNMI', rpc_method_handlers) # This class is part of an EXPERIMENTAL API. @@ -127,11 +148,21 @@ def Capabilities(request, wait_for_ready=None, timeout=None, metadata=None): - return grpc.experimental.unary_unary(request, target, '/gnmi.gNMI/Capabilities', + return grpc.experimental.unary_unary( + request, + target, + '/gnmi.gNMI/Capabilities', gnmi__pb2.CapabilityRequest.SerializeToString, gnmi__pb2.CapabilityResponse.FromString, - options, channel_credentials, - insecure, call_credentials, compression, wait_for_ready, timeout, metadata) + options, + channel_credentials, + insecure, + call_credentials, + compression, + wait_for_ready, + timeout, + metadata, + _registered_method=True) @staticmethod def Get(request, @@ -144,11 +175,21 @@ def Get(request, wait_for_ready=None, timeout=None, metadata=None): - return grpc.experimental.unary_unary(request, target, '/gnmi.gNMI/Get', + return grpc.experimental.unary_unary( + request, + target, + '/gnmi.gNMI/Get', gnmi__pb2.GetRequest.SerializeToString, gnmi__pb2.GetResponse.FromString, - options, channel_credentials, - insecure, call_credentials, compression, wait_for_ready, timeout, metadata) + options, + channel_credentials, + insecure, + call_credentials, + compression, + wait_for_ready, + timeout, + metadata, + _registered_method=True) @staticmethod def Set(request, @@ -161,11 +202,21 @@ def Set(request, wait_for_ready=None, timeout=None, metadata=None): - return grpc.experimental.unary_unary(request, target, '/gnmi.gNMI/Set', + return grpc.experimental.unary_unary( + request, + target, + '/gnmi.gNMI/Set', gnmi__pb2.SetRequest.SerializeToString, gnmi__pb2.SetResponse.FromString, - options, channel_credentials, - insecure, call_credentials, compression, wait_for_ready, timeout, metadata) + options, + channel_credentials, + insecure, + call_credentials, + compression, + wait_for_ready, + timeout, + metadata, + _registered_method=True) @staticmethod def Subscribe(request_iterator, @@ -178,8 +229,18 @@ def Subscribe(request_iterator, wait_for_ready=None, timeout=None, metadata=None): - return grpc.experimental.stream_stream(request_iterator, target, '/gnmi.gNMI/Subscribe', + return grpc.experimental.stream_stream( + request_iterator, + target, + '/gnmi.gNMI/Subscribe', gnmi__pb2.SubscribeRequest.SerializeToString, gnmi__pb2.SubscribeResponse.FromString, - options, channel_credentials, - insecure, call_credentials, compression, wait_for_ready, timeout, metadata) \ No newline at end of file + options, + channel_credentials, + insecure, + call_credentials, + compression, + wait_for_ready, + timeout, + metadata, + _registered_method=True) diff --git a/connector/src/yang/connector/proto/protofiles/gnmi.proto b/connector/src/yang/connector/proto/protofiles/gnmi.proto index da779f65..f52ec10f 100644 --- a/connector/src/yang/connector/proto/protofiles/gnmi.proto +++ b/connector/src/yang/connector/proto/protofiles/gnmi.proto @@ -17,6 +17,7 @@ syntax = "proto3"; import "google/protobuf/any.proto"; import "google/protobuf/descriptor.proto"; + import "gnmi_ext.proto"; // Package gNMI defines a service specification for the gRPC Network Management @@ -303,9 +304,15 @@ message Subscription { // Indicates whether values that have not changed should be sent in a SAMPLE // subscription. bool suppress_redundant = 4; - // Specifies the maximum allowable silent period in nanoseconds when - // suppress_redundant is in use. The target should send a value at least once - // in the period specified. + // 1. A heartbeat interval MAY be specified along with an “on change” + // subscription - in this case, the value of the data item(s) MUST be re-sent + // once per heartbeat interval regardless of whether the value has changed or + // not. + // 2. A heartbeat_interval MAY be specified to modify the behavior of + // suppress_redundant in a sampled subscription. In this case, the + // target MUST generate one telemetry update per heartbeat interval, + // regardless of whether the suppress_redundant flag is set to true. + // This value is specified as an unsigned 64-bit integer in nanoseconds uint64 heartbeat_interval = 5; } @@ -337,11 +344,11 @@ message SetRequest { repeated Path delete = 2; // Paths to be deleted from the data tree. repeated Update replace = 3; // Updates specifying elements to be replaced. repeated Update update = 4; // Updates specifying elements to updated. - // Updates specifying elements to union and then replace the data tree. + // Updates specifying elements to union and then replace the data tree. // See the gNMI specification at // https://github.com/openconfig/reference/blob/master/rpc/gnmi/gnmi-specification.md // for details. - repeated Update union_replace = 6; + repeated Update union_replace = 6; // Extension messages associated with the SetRequest. See the // gNMI extension specification for further definition. repeated gnmi_ext.Extension extension = 5; diff --git a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto index 81aee2ca..ada5e39a 100644 --- a/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto +++ b/connector/src/yang/connector/proto/protofiles/gnmi_ext.proto @@ -15,6 +15,8 @@ // syntax = "proto3"; +import "google/protobuf/duration.proto"; + // Package gnmi_ext defines a set of extensions messages which can be optionally // included with the request and response messages of gNMI RPCs. A set of // well-known extensions are defined within this file, along with a registry for @@ -26,20 +28,20 @@ option go_package = "github.com/openconfig/gnmi/proto/gnmi_ext"; // The Extension message contains a single gNMI extension. message Extension { oneof ext { - RegisteredExtension registered_ext = 1; // A registered extension. + RegisteredExtension registered_ext = 1; // A registered extension. // Well known extensions. MasterArbitration master_arbitration = 2; // Master arbitration extension. History history = 3; // History extension. - Commit commit = 4; - Depth depth = 5; // History extension. + Commit commit = 4; // Commit confirmed extension. + Depth depth = 5; // Depth extension. } } // The RegisteredExtension message defines an extension which is defined outside // of this file. message RegisteredExtension { - ExtensionID id = 1; // The unique ID assigned to this extension. - bytes msg = 2; // The binary-marshalled protobuf extension payload. + ExtensionID id = 1; // The unique ID assigned to this extension. + bytes msg = 2; // The binary-marshalled protobuf extension payload. } // RegisteredExtension is an enumeration acting as a registry for extensions @@ -82,15 +84,16 @@ message Role { // https://github.com/openconfig/reference/blob/master/rpc/gnmi/gnmi-history.md message History { oneof request { - int64 snapshot_time = 1; // Nanoseconds since the epoch + int64 snapshot_time = 1; // Nanoseconds since the epoch TimeRange range = 2; } } message TimeRange { - int64 start = 1; // Nanoseconds since the epoch - int64 end = 2; // Nanoseconds since the epoch + int64 start = 1; // Nanoseconds since the epoch + int64 end = 2; // Nanoseconds since the epoch } + // Commit confirmed extension allows automated revert of the configuration after // certain duration if an explicit confirmation is not issued. It allows // explicit cancellation of the commit during the rollback window. There cannot @@ -140,4 +143,19 @@ message CommitCancel {} message CommitSetRollbackDuration { // Maximum duration to wait for a confirmaton before reverting the commit. google.protobuf.Duration rollback_duration = 1; -} \ No newline at end of file +} + +// Depth allows clients to specify the depth of the subtree to be returned in +// the response. The depth is specified as the number of levels below the +// specified path. +// The depth is applied to all paths in the Get or Subscribe request. +// The document about gNMI depth can be found at +// https://github.com/openconfig/reference/tree/master/rpc/gnmi/gnmi-depth.md +message Depth { + // The level of the subtree to be returned in the response. + // Value of 0 means no depth limit and behaves the same as if the extension + // was not specified. + // Value of 1 means only the specified path and its direct children will be + // returned. + uint32 level = 1; +} From e991341b247259b510c343efb45b5d7d989bab95 Mon Sep 17 00:00:00 2001 From: sodn Date: Thu, 21 Nov 2024 10:58:54 +0000 Subject: [PATCH 6/7] fixed version --- connector/setup.py | 8 ++++---- connector/src/yang/connector/proto/gnmi_pb2.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/connector/setup.py b/connector/setup.py index b2074c2a..92f7ea8f 100755 --- a/connector/setup.py +++ b/connector/setup.py @@ -182,10 +182,10 @@ def find_version(*paths): 'paramiko >= 3.5.0', 'lxml >= 4.9.4, <5.0.0', 'ncclient >= 0.6.16', - 'grpcio >= 1.67.1', - 'grpcio-tools >= 1.67.1', - 'googleapis-common-protos >= 1.65.0', - 'protobuf >= 5.28.3' + 'grpcio >= 1.68.0', + 'grpcio-tools >= 1.68.0', + 'googleapis-common-protos >= 1.66.0', + 'protobuf >= 5.26.1' ], # any additional groups of dependencies. diff --git a/connector/src/yang/connector/proto/gnmi_pb2.py b/connector/src/yang/connector/proto/gnmi_pb2.py index 572a3ee2..635fbd73 100644 --- a/connector/src/yang/connector/proto/gnmi_pb2.py +++ b/connector/src/yang/connector/proto/gnmi_pb2.py @@ -24,7 +24,7 @@ from google.protobuf import any_pb2 as google_dot_protobuf_dot_any__pb2 from google.protobuf import descriptor_pb2 as google_dot_protobuf_dot_descriptor__pb2 -from . import gnmi_ext_pb2 as gnmi__ext__pb2 +from . import gnmi_ext_pb2 as gnmi__ext__pb2 DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\ngnmi.proto\x12\x04gnmi\x1a\x19google/protobuf/any.proto\x1a google/protobuf/descriptor.proto\x1a\x0egnmi_ext.proto\"\x94\x01\n\x0cNotification\x12\x11\n\ttimestamp\x18\x01 \x01(\x03\x12\x1a\n\x06prefix\x18\x02 \x01(\x0b\x32\n.gnmi.Path\x12\x1c\n\x06update\x18\x04 \x03(\x0b\x32\x0c.gnmi.Update\x12\x1a\n\x06\x64\x65lete\x18\x05 \x03(\x0b\x32\n.gnmi.Path\x12\x0e\n\x06\x61tomic\x18\x06 \x01(\x08J\x04\x08\x03\x10\x04R\x05\x61lias\"u\n\x06Update\x12\x18\n\x04path\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12\x1e\n\x05value\x18\x02 \x01(\x0b\x32\x0b.gnmi.ValueB\x02\x18\x01\x12\x1d\n\x03val\x18\x03 \x01(\x0b\x32\x10.gnmi.TypedValue\x12\x12\n\nduplicates\x18\x04 \x01(\r\"\x83\x03\n\nTypedValue\x12\x14\n\nstring_val\x18\x01 \x01(\tH\x00\x12\x11\n\x07int_val\x18\x02 \x01(\x03H\x00\x12\x12\n\x08uint_val\x18\x03 \x01(\x04H\x00\x12\x12\n\x08\x62ool_val\x18\x04 \x01(\x08H\x00\x12\x13\n\tbytes_val\x18\x05 \x01(\x0cH\x00\x12\x17\n\tfloat_val\x18\x06 \x01(\x02\x42\x02\x18\x01H\x00\x12\x14\n\ndouble_val\x18\x0e \x01(\x01H\x00\x12*\n\x0b\x64\x65\x63imal_val\x18\x07 \x01(\x0b\x32\x0f.gnmi.Decimal64B\x02\x18\x01H\x00\x12)\n\x0cleaflist_val\x18\x08 \x01(\x0b\x32\x11.gnmi.ScalarArrayH\x00\x12\'\n\x07\x61ny_val\x18\t \x01(\x0b\x32\x14.google.protobuf.AnyH\x00\x12\x12\n\x08json_val\x18\n \x01(\x0cH\x00\x12\x17\n\rjson_ietf_val\x18\x0b \x01(\x0cH\x00\x12\x13\n\tascii_val\x18\x0c \x01(\tH\x00\x12\x15\n\x0bproto_bytes\x18\r \x01(\x0cH\x00\x42\x07\n\x05value\"Y\n\x04Path\x12\x13\n\x07\x65lement\x18\x01 \x03(\tB\x02\x18\x01\x12\x0e\n\x06origin\x18\x02 \x01(\t\x12\x1c\n\x04\x65lem\x18\x03 \x03(\x0b\x32\x0e.gnmi.PathElem\x12\x0e\n\x06target\x18\x04 \x01(\t\"j\n\x08PathElem\x12\x0c\n\x04name\x18\x01 \x01(\t\x12$\n\x03key\x18\x02 \x03(\x0b\x32\x17.gnmi.PathElem.KeyEntry\x1a*\n\x08KeyEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"8\n\x05Value\x12\r\n\x05value\x18\x01 \x01(\x0c\x12\x1c\n\x04type\x18\x02 \x01(\x0e\x32\x0e.gnmi.Encoding:\x02\x18\x01\"N\n\x05\x45rror\x12\x0c\n\x04\x63ode\x18\x01 \x01(\r\x12\x0f\n\x07message\x18\x02 \x01(\t\x12\"\n\x04\x64\x61ta\x18\x03 \x01(\x0b\x32\x14.google.protobuf.Any:\x02\x18\x01\"2\n\tDecimal64\x12\x0e\n\x06\x64igits\x18\x01 \x01(\x03\x12\x11\n\tprecision\x18\x02 \x01(\r:\x02\x18\x01\"0\n\x0bScalarArray\x12!\n\x07\x65lement\x18\x01 \x03(\x0b\x32\x10.gnmi.TypedValue\"\x9d\x01\n\x10SubscribeRequest\x12+\n\tsubscribe\x18\x01 \x01(\x0b\x32\x16.gnmi.SubscriptionListH\x00\x12\x1a\n\x04poll\x18\x03 \x01(\x0b\x32\n.gnmi.PollH\x00\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.ExtensionB\t\n\x07requestJ\x04\x08\x04\x10\x05R\x07\x61liases\"\x06\n\x04Poll\"\xa8\x01\n\x11SubscribeResponse\x12$\n\x06update\x18\x01 \x01(\x0b\x32\x12.gnmi.NotificationH\x00\x12\x17\n\rsync_response\x18\x03 \x01(\x08H\x00\x12 \n\x05\x65rror\x18\x04 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01H\x00\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.ExtensionB\n\n\x08response\"\xd5\x02\n\x10SubscriptionList\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12(\n\x0csubscription\x18\x02 \x03(\x0b\x32\x12.gnmi.Subscription\x12\x1d\n\x03qos\x18\x04 \x01(\x0b\x32\x10.gnmi.QOSMarking\x12)\n\x04mode\x18\x05 \x01(\x0e\x32\x1b.gnmi.SubscriptionList.Mode\x12\x19\n\x11\x61llow_aggregation\x18\x06 \x01(\x08\x12#\n\nuse_models\x18\x07 \x03(\x0b\x32\x0f.gnmi.ModelData\x12 \n\x08\x65ncoding\x18\x08 \x01(\x0e\x32\x0e.gnmi.Encoding\x12\x14\n\x0cupdates_only\x18\t \x01(\x08\"&\n\x04Mode\x12\n\n\x06STREAM\x10\x00\x12\x08\n\x04ONCE\x10\x01\x12\x08\n\x04POLL\x10\x02J\x04\x08\x03\x10\x04R\x0buse_aliases\"\x9f\x01\n\x0cSubscription\x12\x18\n\x04path\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12$\n\x04mode\x18\x02 \x01(\x0e\x32\x16.gnmi.SubscriptionMode\x12\x17\n\x0fsample_interval\x18\x03 \x01(\x04\x12\x1a\n\x12suppress_redundant\x18\x04 \x01(\x08\x12\x1a\n\x12heartbeat_interval\x18\x05 \x01(\x04\"\x1d\n\nQOSMarking\x12\x0f\n\x07marking\x18\x01 \x01(\r\"\xce\x01\n\nSetRequest\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12\x1a\n\x06\x64\x65lete\x18\x02 \x03(\x0b\x32\n.gnmi.Path\x12\x1d\n\x07replace\x18\x03 \x03(\x0b\x32\x0c.gnmi.Update\x12\x1c\n\x06update\x18\x04 \x03(\x0b\x32\x0c.gnmi.Update\x12#\n\runion_replace\x18\x06 \x03(\x0b\x32\x0c.gnmi.Update\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.Extension\"\xac\x01\n\x0bSetResponse\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12$\n\x08response\x18\x02 \x03(\x0b\x32\x12.gnmi.UpdateResult\x12 \n\x07message\x18\x03 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01\x12\x11\n\ttimestamp\x18\x04 \x01(\x03\x12&\n\textension\x18\x05 \x03(\x0b\x32\x13.gnmi_ext.Extension\"\xdd\x01\n\x0cUpdateResult\x12\x15\n\ttimestamp\x18\x01 \x01(\x03\x42\x02\x18\x01\x12\x18\n\x04path\x18\x02 \x01(\x0b\x32\n.gnmi.Path\x12 \n\x07message\x18\x03 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01\x12(\n\x02op\x18\x04 \x01(\x0e\x32\x1c.gnmi.UpdateResult.Operation\"P\n\tOperation\x12\x0b\n\x07INVALID\x10\x00\x12\n\n\x06\x44\x45LETE\x10\x01\x12\x0b\n\x07REPLACE\x10\x02\x12\n\n\x06UPDATE\x10\x03\x12\x11\n\rUNION_REPLACE\x10\x04\"\x97\x02\n\nGetRequest\x12\x1a\n\x06prefix\x18\x01 \x01(\x0b\x32\n.gnmi.Path\x12\x18\n\x04path\x18\x02 \x03(\x0b\x32\n.gnmi.Path\x12\'\n\x04type\x18\x03 \x01(\x0e\x32\x19.gnmi.GetRequest.DataType\x12 \n\x08\x65ncoding\x18\x05 \x01(\x0e\x32\x0e.gnmi.Encoding\x12#\n\nuse_models\x18\x06 \x03(\x0b\x32\x0f.gnmi.ModelData\x12&\n\textension\x18\x07 \x03(\x0b\x32\x13.gnmi_ext.Extension\";\n\x08\x44\x61taType\x12\x07\n\x03\x41LL\x10\x00\x12\n\n\x06\x43ONFIG\x10\x01\x12\t\n\x05STATE\x10\x02\x12\x0f\n\x0bOPERATIONAL\x10\x03\"\x7f\n\x0bGetResponse\x12(\n\x0cnotification\x18\x01 \x03(\x0b\x32\x12.gnmi.Notification\x12\x1e\n\x05\x65rror\x18\x02 \x01(\x0b\x32\x0b.gnmi.ErrorB\x02\x18\x01\x12&\n\textension\x18\x03 \x03(\x0b\x32\x13.gnmi_ext.Extension\";\n\x11\x43\x61pabilityRequest\x12&\n\textension\x18\x01 \x03(\x0b\x32\x13.gnmi_ext.Extension\"\xaa\x01\n\x12\x43\x61pabilityResponse\x12)\n\x10supported_models\x18\x01 \x03(\x0b\x32\x0f.gnmi.ModelData\x12+\n\x13supported_encodings\x18\x02 \x03(\x0e\x32\x0e.gnmi.Encoding\x12\x14\n\x0cgNMI_version\x18\x03 \x01(\t\x12&\n\textension\x18\x04 \x03(\x0b\x32\x13.gnmi_ext.Extension\"@\n\tModelData\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0corganization\x18\x02 \x01(\t\x12\x0f\n\x07version\x18\x03 \x01(\t*D\n\x08\x45ncoding\x12\x08\n\x04JSON\x10\x00\x12\t\n\x05\x42YTES\x10\x01\x12\t\n\x05PROTO\x10\x02\x12\t\n\x05\x41SCII\x10\x03\x12\r\n\tJSON_IETF\x10\x04*A\n\x10SubscriptionMode\x12\x12\n\x0eTARGET_DEFINED\x10\x00\x12\r\n\tON_CHANGE\x10\x01\x12\n\n\x06SAMPLE\x10\x02\x32\xe3\x01\n\x04gNMI\x12\x41\n\x0c\x43\x61pabilities\x12\x17.gnmi.CapabilityRequest\x1a\x18.gnmi.CapabilityResponse\x12*\n\x03Get\x12\x10.gnmi.GetRequest\x1a\x11.gnmi.GetResponse\x12*\n\x03Set\x12\x10.gnmi.SetRequest\x1a\x11.gnmi.SetResponse\x12@\n\tSubscribe\x12\x16.gnmi.SubscribeRequest\x1a\x17.gnmi.SubscribeResponse(\x01\x30\x01:3\n\x0cgnmi_service\x12\x1c.google.protobuf.FileOptions\x18\xe9\x07 \x01(\tBT\n\x15\x63om.github.gnmi.protoB\tGnmiProtoP\x01Z%github.com/openconfig/gnmi/proto/gnmi\xca>\x06\x30.10.0b\x06proto3') From de9153b34aed0f147a245320f34c4068a67044f7 Mon Sep 17 00:00:00 2001 From: Sowmya D N Date: Tue, 13 May 2025 14:52:47 +0530 Subject: [PATCH 7/7] Updated the packages --- connector/setup.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/connector/setup.py b/connector/setup.py index 92f7ea8f..ca645a98 100755 --- a/connector/setup.py +++ b/connector/setup.py @@ -179,13 +179,13 @@ def find_version(*paths): # package dependencies install_requires = [ - 'paramiko >= 3.5.0', - 'lxml >= 4.9.4, <5.0.0', - 'ncclient >= 0.6.16', - 'grpcio >= 1.68.0', - 'grpcio-tools >= 1.68.0', - 'googleapis-common-protos >= 1.66.0', - 'protobuf >= 5.26.1' + 'paramiko >= 3.5.1', + 'lxml >= 4.9.4, <5.4.0', + 'ncclient >= 0.6.19', + 'grpcio >= 1.71.0', + 'grpcio-tools >= 1.71.0', + 'googleapis-common-protos >= 1.70.0', + 'protobuf >= 6.30.2' ], # any additional groups of dependencies.