gRPC Client
Supported pipeline types:
|
Use the gRPC Client origin only in pipelines configured for edge execution mode. Run the pipeline on StreamSets Data Collector Edge (SDC Edge).
When you configure the gRPC Client origin, you specify the resource URL of the gRPC server and the service method that the origin calls. You also define whether the origin uses the unary or server streaming RPC method to call the server.
You can specify optional headers that the origin sends with the request, and configure whether the gRPC server can send default values in the response. You can also optionally configure the origin to use SSL/TLS to securely connect to the gRPC server.
For more information about installing SDC Edge, designing edge pipelines, and running and maintaining edge pipelines, see Edge Pipelines Overview.
Prerequisite
Before the gRPC Client origin can process data from a gRPC server, you must enable reflection for the server.
To enable server reflection, import the gRPC reflection package and then register reflection service on the gRPC server, as described in this gRPC Server Reflection Tutorial.
Server Method Type
The gRPC Client origin can use one of the following method types to call the gRPC server:
- Unary RPC method
- With the unary RPC method, the origin sends a single request to the gRPC server and receives a single response back, just like a normal function call.
- Server streaming RPC method
- With the server streaming RPC method, the origin sends a request to the gRPC server and receives a stream to read a sequence of messages back. The client reads from the returned stream until there are no more messages.
For more information about these gRPC server method types, see the gRPC documentation.
Data Formats
The gRPC Client origin processes data differently based on the data format. The origin processes the following types of data:
- Delimited
- Generates a record for each delimited line. You can use the
following delimited format types:
- Default CSV - File that includes comma-separated values. Ignores empty lines in the file.
- RFC4180 CSV - Comma-separated file that strictly follows RFC4180 guidelines.
- MS Excel CSV - Microsoft Excel comma-separated file.
- MySQL CSV - MySQL comma-separated file.
- Tab-Separated Values - File that includes tab-separated values.
- PostgreSQL CSV - PostgreSQL comma-separated file.
- PostgreSQL Text - PostgreSQL text file.
- Custom - File that uses user-defined delimiter, escape, and quote characters.
- Multi Character Delimited - File that uses multiple user-defined characters to delimit fields and lines, and single user-defined escape and quote characters.
- JSON
- Generates a record for each JSON object. You can process JSON files that include multiple JSON objects or a single JSON array.
- Text
- Generates a record for each line of text or for each section of text based on a custom delimiter.
Configuring a gRPC Client Origin
Configure a gRPC Client origin to read from a gRPC server. The gRPC Client origin is a Technology Preview feature. It is not meant for use in production.