Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Streaming Indexing] Introduce bulk HTTP API streaming flavor #15381

Merged
merged 4 commits into from
Aug 28, 2024

Conversation

reta
Copy link
Collaborator

@reta reta commented Aug 23, 2024

Description

Introduce bulk HTTP API streaming flavor

Related Issues

Closes #9070

Check List

  • Functionality includes testing.
  • API changes companion pull request created, if applicable.
  • Public documentation issue/PR created, if applicable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@github-actions github-actions bot added enhancement Enhancement or improvement to existing feature or request Indexing Indexing, Bulk Indexing and anything related to indexing v3.0.0 Issues and PRs related to version 3.0.0 labels Aug 23, 2024
@reta reta added the backport 2.x Backport to 2.x branch label Aug 23, 2024
Copy link
Contributor

❌ Gradle check result for 0a25d48: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Copy link
Contributor

❌ Gradle check result for 503e05e: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Copy link
Contributor

❌ Gradle check result for b8d2274: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Copy link
Contributor

❌ Gradle check result for e4f4a0b: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Copy link
Contributor

✅ Gradle check result for 20f72eb: SUCCESS

Copy link

codecov bot commented Aug 27, 2024

Codecov Report

Attention: Patch coverage is 12.00000% with 44 lines in your changes missing coverage. Please review.

Project coverage is 71.90%. Comparing base (23cba28) to head (62b27d2).
Report is 1 commits behind head on main.

Files Patch % Lines
...rc/main/java/org/opensearch/client/RestClient.java 0.00% 22 Missing ⚠️
.../rest/action/document/RestBulkStreamingAction.java 12.00% 20 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main   #15381      +/-   ##
============================================
- Coverage     71.91%   71.90%   -0.02%     
- Complexity    63311    63326      +15     
============================================
  Files          5225     5225              
  Lines        296350   296389      +39     
  Branches      42809    42818       +9     
============================================
- Hits         213119   213113       -6     
- Misses        65743    65811      +68     
+ Partials      17488    17465      -23     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
Copy link
Contributor

❌ Gradle check result for 5b3087a: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

Copy link
Contributor

✅ Gradle check result for 9c1aad3: SUCCESS

@reta
Copy link
Collaborator Author

reta commented Aug 28, 2024

@andrross thanks a mill for approving, conflicts resolved + more tests added, could you please reapprove? thank you!

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
Copy link
Contributor

❕ Gradle check result for 62b27d2: UNSTABLE

Please review all flaky tests that succeeded after retry and create an issue if one does not already exist to track the flaky failure.

@reta reta merged commit 8d17c8d into opensearch-project:main Aug 28, 2024
33 of 34 checks passed
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.x failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/OpenSearch/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/OpenSearch/backport-2.x
# Create a new branch
git switch --create backport/backport-15381-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 8d17c8d87e67db8924ed66ab0128f0bdc6aff274
# Push it to GitHub
git push --set-upstream origin backport/backport-15381-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/OpenSearch/backport-2.x

Then, create a pull request where the base branch is 2.x and the compare/head branch is backport/backport-15381-to-2.x.

* @param b {@link ByteBuffer} to split
* @return individual chunks
*/
private static Collection<ByteBuffer> frame(ByteBuffer b) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a good candidate for a unit test. What do you think?

Copy link
Collaborator Author

@reta reta Aug 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My apologies, have seen the comment after merge only. Sadly our codecov captures only limited subset of tests, the ReactorNetty4StreamingIT covers this method in full, from my local code coverage report:

image

I will try to figure out what we could do here to have codecov capturing more.

reta added a commit to reta/OpenSearch that referenced this pull request Aug 28, 2024
…arch-project#15381)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
(cherry picked from commit 8d17c8d)
reta added a commit to reta/OpenSearch that referenced this pull request Aug 28, 2024
…arch-project#15381)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
(cherry picked from commit 8d17c8d)
reta added a commit that referenced this pull request Aug 28, 2024
#15472)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
(cherry picked from commit 8d17c8d)
akolarkunnu pushed a commit to akolarkunnu/OpenSearch that referenced this pull request Sep 10, 2024
…arch-project#15381)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
dk2k pushed a commit to dk2k/OpenSearch that referenced this pull request Oct 16, 2024
…arch-project#15381)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
dk2k pushed a commit to dk2k/OpenSearch that referenced this pull request Oct 17, 2024
…arch-project#15381)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
dk2k pushed a commit to dk2k/OpenSearch that referenced this pull request Oct 21, 2024
…arch-project#15381)

* [Streaming Indexing] Introduce bulk HTTP API streaming flavor

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Address code review comments

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

* Add more test cases

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>

---------

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x Backport to 2.x branch backport-failed enhancement Enhancement or improvement to existing feature or request Indexing Indexing, Bulk Indexing and anything related to indexing v2.17.0 v3.0.0 Issues and PRs related to version 3.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Streaming Indexing] Introduce bulk HTTP API streaming flavour
2 participants