Generating the GPSS Client Classes
A newer version of this documentation is available. Use the version menu above to view the most up-to-date release of the Greenplum 6.x documentation.
Generating the GPSS Client Classes
The Greenplum Stream Server service definition defines the messages and services exposed by the GPSS gRPC server. This definition resides in the gpss.proto file. You must run the protocol buffer compiler (protoc) on the gpss.proto file to generate the classes that the GPSS client uses to query metadata information from, and write data to, Greenplum Database.
In some build environments such as gradle, you can configure the build to automatically generate the GPSS client classes for you. Refer to the gRPC examples for your programming language for sample build configurations with automatic code generation. For example, the gradle build and settings files for the examples in the grpc-java repository are configured to automatically generate the Java classes for you.
$ protoc --plugin=protoc-gen-grpc-java=../grpc-java/compiler/build/exe/java_plugin/protoc-gen-grpc-java \ --proto_path=./src/main/proto --grpc-java_out=./gen/grpc/ \ --java_out=./gen/java/ gpss.proto