Closed
Conversation
mattyb149
reviewed
Aug 21, 2024
| .name("Maximum Batch Size") | ||
| .description("Specifies the maximum number of records to send in the body of each HTTP request. Zero means the batch size is not limited, " | ||
| + "and all records are sent together in a single HTTP request.") | ||
| .defaultValue("1") |
Contributor
There was a problem hiding this comment.
I think the default should be zero, it can be set to 1 for users of Kafka for example, but since you get a whole record set at once via the API, we should default to send them all. This mimics the behavior of InvokeHttp. @exceptionfactory had some comments on the processor version of this in #8127 and its predecessors for the processor version of this. For this use case it's good as a RecordSink especially for QueryNiFiReportingTask.
| return writeResult; | ||
| } | ||
|
|
||
| public void sendHttpRequest(final byte[] body, String mimeType) { // throws IOException { |
Contributor
There was a problem hiding this comment.
Should this throw the IOException to get caught "upstream"? If not this comment can be removed
…eption from sendHttpRequest()
Contributor
|
+1 LGTM, verified the changes and the behavior is as expected. Thanks for the new feature! Merging to main |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
NIFI-13543
Tracking
Please complete the following tracking steps prior to pull request creation.
Issue Tracking
Pull Request Tracking
NIFI-00000NIFI-00000Pull Request Formatting
mainbranchVerification
Automated unit test were written and executed successfully.
The HttpRecordSink was tested from the NiFi ui and worked as intended.
Build
mvn clean install -P contrib-checkLicensing
LICENSEandNOTICEfilesDocumentation