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

#1474 -- catch OpenSearchExceptions to prevent percolation of Runtime… #1476

Merged
merged 3 commits into from
Feb 24, 2025

Conversation

tballison
Copy link
Contributor

@tballison tballison commented Feb 21, 2025

…Exceptions, including check-then-update race condition in creating an index.

My guess is that the original intention was to catch everything from the client. However, the client can throw an OpenSearchStatusException which extends OpenSearchException which extends RuntimeException.

This catches and logs problems creating indices and templates.

The initial bug to fix was a "check-the-update" race condition if there are multiple status bolts, for example. This solution may be too broad.

I didn't add a unit test, because I think this is a pretty small fix, and it didn't warrant multithreading the creation of several bolts.

Let me know what you think.

Thank you for contributing to Apache StormCrawler.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

For all changes:

  • Is there a issue associated with this PR? Is it referenced in the commit message?

  • Does your PR title start with #XXXX where XXXX is the issue number you are trying to resolve?

  • Has your PR been rebased against the latest commit within the target branch (typically main)?

  • Is your initial contribution a single, squashed commit?

  • Is the code properly formatted with mvn git-code-format:format-code -Dgcf.globPattern="**/*" -Dskip.format.code=false?

For code changes:

  • Have you ensured that the full suite of tests is executed via mvn clean verify?
  • Have you written or updated unit tests to verify your changes?
  • If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?
  • If applicable, have you updated the LICENSE file, including the main LICENSE file?
  • If applicable, have you updated the NOTICE file, including the main NOTICE file?

Note:

Please ensure that once the PR is submitted, you check GitHub Actions for build issues and submit an update to your PR as soon as possible.

…Exceptions, including check-then-update race condition in creating an index.
@tballison tballison requested a review from jnioche February 21, 2025 15:41
@tballison tballison merged commit 4c1b630 into main Feb 24, 2025
2 checks passed
@tballison tballison deleted the issue-1474 branch February 24, 2025 16:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants