InvokeGRPC

Deprecation notice:

No planned alternatives to be offered. Use custom processors instead.

Please consider using one the following alternatives: No alternative components suggested.

Description:

Sends FlowFiles, optionally with content, to a configurable remote gRPC service endpoint. The remote gRPC service must abide by the service IDL defined in NiFi. gRPC isn't intended to carry large payloads, so this processor should be used only when FlowFile sizes are on the order of megabytes. The default maximum message size is 4MB.

Tags:

grpc, rpc, client

Properties:

In the list below, the names of required properties appear in bold. Any other properties (not in bold) are considered optional. The table also indicates any default values.

Display NameAPI NameDefault ValueAllowable ValuesDescription
Remote gRPC service hostnameRemote gRPC service hostnameRemote host which will be connected to
Remote gRPC service portRemote gRPC service portRemote port which will be connected to
Max Message SizeMax Message Size4MBThe maximum size of FlowFiles that this processor will allow to be received. The default is 4MB. If FlowFiles exceed this size, you should consider using another transport mechanism as gRPC isn't designed for heavy payloads.
Use TLSUse SSL/TLSfalse
  • true
  • false
Whether or not to use TLS to send the contents of the gRPC messages.
SSL Context ServiceSSL Context ServiceController Service API:
SSLContextService
Implementations: StandardSSLContextService
StandardRestrictedSSLContextService
The SSL Context Service used to provide client certificate information for TLS (https) connections.

This Property is only considered if the [Use TLS] Property has a value of "true".
Send FlowFile ContentSend FlowFile Contenttrue
  • true
  • false
Whether or not to include the FlowFile content in the FlowFileRequest to the gRPC service.
Always Output ResponseAlways Output Responsefalse
  • true
  • false
Will force a response FlowFile to be generated and routed to the 'Response' relationship regardless of what the server status code received is or if the processor is configured to put the server response body in the request attribute. In the later configuration a request FlowFile with the response body in the attribute and a typical response FlowFile will be emitted to their respective relationships.
Penalize on "No Retry"Penalize on "No Retry"false
  • true
  • false
Enabling this property will penalize FlowFiles that are routed to the "No Retry" relationship.

Relationships:

NameDescription
OriginalThe original FlowFile will be routed upon success. It will have new attributes detailing the success of the request.
FailureThe original FlowFile will be routed on any type of connection failure, timeout or general exception. It will have new attributes detailing the request.
RetryThe original FlowFile will be routed on any status code that can be retried. It will have new attributes detailing the request.
No RetryThe original FlowFile will be routed on any status code that should NOT be retried. It will have new attributes detailing the request.
ResponseA Response FlowFile will be routed upon success. If the 'Output Response Regardless' property is true then the response will be sent to this relationship regardless of the status code received.

Reads Attributes:

None specified.

Writes Attributes:

NameDescription
invokegrpc.response.codeThe response code that is returned (0 = ERROR, 1 = SUCCESS, 2 = RETRY)
invokegrpc.response.bodyThe response message that is returned
invokegrpc.service.hostThe remote gRPC service hostname
invokegrpc.service.portThe remote gRPC service port
invokegrpc.java.exception.classThe Java exception class raised when the processor fails
invokegrpc.java.exception.messageThe Java exception message raised when the processor fails

State management:

This component does not store state.

Restricted:

This component is not restricted.

Input requirement:

This component requires an incoming relationship.

System Resource Considerations:

None specified.