Refactored protobuf framework, added loader
Included changes:
* Initial adapter interface spec
* Adapter loader to auto-load adapters
* Initial adapter NBI
* Better import support in chameleon, allowing more flexible
protobuf structure (by organizing artifacts and service
into separate proto files.
* Refactored voltha.proto to split things into logical proto
modules.
* Some additional cleanup
Change-Id: I75f9883c6992148ea8df430bcdaebf85115fea4a
diff --git a/chameleon/grpc_client/grpc_client.py b/chameleon/grpc_client/grpc_client.py
index 75c78eb..9a95330 100644
--- a/chameleon/grpc_client/grpc_client.py
+++ b/chameleon/grpc_client/grpc_client.py
@@ -16,7 +16,7 @@
"""
gRPC client meant to connect to a gRPC server endpoint, and query the
-end-point's schema by calling SchemaService.Schema(NullMessage) and all of its
+end-point's schema by calling SchemaService.Schema(Empty) and all of its
semantics are derived from the recovered schema.
"""
@@ -34,7 +34,9 @@
from werkzeug.exceptions import ServiceUnavailable
from common.utils.asleep import asleep
-from chameleon.protos.schema_pb2 import NullMessage, SchemaServiceStub
+from chameleon.protos.schema_pb2 import SchemaServiceStub
+from google.protobuf.empty_pb2 import Empty
+
log = get_logger()
@@ -165,7 +167,7 @@
assert isinstance(self.channel, grpc.Channel)
stub = SchemaServiceStub(self.channel)
# try:
- schemas = stub.GetSchema(NullMessage())
+ schemas = stub.GetSchema(Empty())
# except _Rendezvous, e:
# if e.code == grpc.StatusCode.UNAVAILABLE:
#