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

Add completion count in SearchBackpressure nodeStats API #8701

Closed
wants to merge 331 commits into from

Conversation

kaushalmahi12
Copy link
Contributor

@kaushalmahi12 kaushalmahi12 commented Jul 14, 2023

Description

With this change the nodeStats API will also return the completionCount of search tasks at shard and coordinator level.

new sample response for an API call like curl "localhost:9200/_nodes/stats/search_backpressure?pretty" will look like the following

{
  "_nodes" : {
    "total" : 1,
    "successful" : 1,
    "failed" : 0
  },
  "cluster_name" : "runTask",
  "nodes" : {
    "dPpgbce2STSxlvH7LDaGiA" : {
      "timestamp" : 1693433903192,
      "name" : "runTask-0",
      "transport_address" : "127.0.0.1:9300",
      "host" : "127.0.0.1",
      "ip" : "127.0.0.1:9300",
      "roles" : [
        "cluster_manager",
        "data",
        "ingest",
        "remote_cluster_client"
      ],
      "attributes" : {
        "testattr" : "test",
        "shard_indexing_pressure_enabled" : "true"
      },
      "search_backpressure" : {
        "search_task" : {
          "resource_tracker_stats" : {
            "cpu_usage_tracker" : {
              "cancellation_count" : 0,
              "current_max_millis" : 0,
              "current_avg_millis" : 0
            },
            "elapsed_time_tracker" : {
              "cancellation_count" : 0,
              "current_max_millis" : 0,
              "current_avg_millis" : 0
            },
            "heap_usage_tracker" : {
              "cancellation_count" : 0,
              "current_max_bytes" : 0,
              "current_avg_bytes" : 0,
              "rolling_avg_bytes" : 0
            }
          },
          "completion_count" : 0,
          "cancellation_stats" : {
            "cancellation_count" : 0,
            "cancellation_limit_reached_count" : 0
          }
        },
        "search_shard_task" : {
          "resource_tracker_stats" : {
            "cpu_usage_tracker" : {
              "cancellation_count" : 0,
              "current_max_millis" : 0,
              "current_avg_millis" : 0
            },
            "elapsed_time_tracker" : {
              "cancellation_count" : 0,
              "current_max_millis" : 0,
              "current_avg_millis" : 0
            },
            "heap_usage_tracker" : {
              "cancellation_count" : 0,
              "current_max_bytes" : 0,
              "current_avg_bytes" : 0,
              "rolling_avg_bytes" : 0
            }
          },
          "completion_count" : 0,
          "cancellation_stats" : {
            "cancellation_count" : 0,
            "cancellation_limit_reached_count" : 0
          }
        },
        "mode" : "monitor_only"
      },
      "is_node_under_duress" : false
    }
  }
}

Related Issues

Resolves #8698

Check List

  • New functionality includes testing.
    • All tests pass
  • New functionality has been documented.
    • New functionality has javadoc added
  • Commits are signed per the DCO using --signoff
  • Commit changes are listed out in CHANGELOG.md file (See: Changelog)

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
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

Copy link
Contributor

@PritLadani PritLadani left a comment

Choose a reason for hiding this comment

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

Shall we also include a metric suggesting whether the node is under duress or not? It will be useful for investigation.
IsNodeUnderDuress can be added in the SearchBackpressureStats pojo.

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@kaushalmahi12 kaushalmahi12 requested a review from sohami as a code owner July 26, 2023 19:55
@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

linuxpi and others added 20 commits September 12, 2023 10:56
* Fix default tracer falky test

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

---------

Signed-off-by: Gagan Juneja <[email protected]>
Co-authored-by: Gagan Juneja <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
…pensearch-project#9727)

* Improve performance of rounding dates in date_histogram aggregation

Signed-off-by: Ketan Verma <[email protected]>

* Minor refactoring changes

Signed-off-by: Ketan Verma <[email protected]>

---------

Signed-off-by: Ketan Verma <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
…peTestCase annotation (opensearch-project#9916)

Signed-off-by: Neetika Singhal <[email protected]>
Signed-off-by: Andriy Redko <[email protected]>
Co-authored-by: Andriy Redko <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
…nt Replication (opensearch-project#9585)

* support realtime TermVector and MultiTermVector requests with segment replication.

Signed-off-by: Rishikesh1159 <[email protected]>

* Fix TermVector requests with segrep.

Signed-off-by: Rishikesh1159 <[email protected]>

* Refacotring.

Signed-off-by: Rishikesh1159 <[email protected]>

* Address comments on PR.

Signed-off-by: Rishikesh1159 <[email protected]>

---------

Signed-off-by: Rishikesh1159 <[email protected]>
Signed-off-by: Rishikesh Pasham <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
…ject#9415)

* Add Instrumentation

Signed-off-by: Gagan Juneja <[email protected]>

* update changelog

Signed-off-by: Gagan Juneja <[email protected]>

* clear the context

Signed-off-by: Gagan Juneja <[email protected]>

* Add Instrumentation

Signed-off-by: Gagan Juneja <[email protected]>

* Fix test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Add Instrumentation

Signed-off-by: Gagan Juneja <[email protected]>

* Add Instrumentation

Signed-off-by: Gagan Juneja <[email protected]>

* Remove internal transport action check

Signed-off-by: Gagan Juneja <[email protected]>

* Changes

Signed-off-by: Gagan Juneja <[email protected]>

* Refactor code

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Fix failing test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Fix failing test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Fix failing test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Fix failing test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Fix failing test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Fix failing test cases

Signed-off-by: Gagan Juneja <[email protected]>

* Fix java doc

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Address merge conflicts

Signed-off-by: Gagan Juneja <[email protected]>

* Address merge conflicts

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Enable NumberOfTraceIDsEqualToRequests test

Signed-off-by: Gagan Juneja <[email protected]>

* Fix java doc

Signed-off-by: Gagan Juneja <[email protected]>

* Fix java doc

Signed-off-by: Gagan Juneja <[email protected]>

* Empty-Commit

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Address review comment

Signed-off-by: Gagan Juneja <[email protected]>

* Fix test case

Signed-off-by: Gagan Juneja <[email protected]>

* Remove instrumentation from TransportService

Signed-off-by: Gagan Juneja <[email protected]>

---------

Signed-off-by: Gagan Juneja <[email protected]>
Signed-off-by: Gagan Juneja <[email protected]>
Co-authored-by: Gagan Juneja <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
This plugin has been moved to its own [repository][1].

[1]: https://github.com/opensearch-project/custom-codecs

Signed-off-by: Andrew Ross <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
* Clear CHANGELOG for released 2.x changes

Signed-off-by: Kunal Kotwani <[email protected]>

* Add release notes for 2.10

Signed-off-by: Kunal Kotwani <[email protected]>

---------

Signed-off-by: Kunal Kotwani <[email protected]>
…ject#9956)

Fix is pending in opensearch-project#7771, but that PR may take some time to land in main
so muting for the time being.

Signed-off-by: Andrew Ross <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
Instead of appending a new comment every time check compatibility runs,
this will instead update a single comment with the latest results. The
history of previous runs is retained in the comment as GitHub allows you
to view the edited revisions of any comment. This matches the behavior
of the codecov workflow and should substantially reduce noise in PRs.

Relates opensearch-project#9699

Signed-off-by: Andrew Ross <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
* fixing javadoc of org.opensearch.cli.Terminal

Signed-off-by: Laurent Laborde <[email protected]>

* fixing javadoc of org.opensearch.cli.ExitCodes

Signed-off-by: Laurent Laborde <[email protected]>

* fixing javadoc

Signed-off-by: Laurent Laborde <[email protected]>

* fixing a mishap in formatting rule

Signed-off-by: Laurent Laborde <[email protected]>

---------

Signed-off-by: Laurent Laborde <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
…ject#9575)

* Bump peter-evans/create-or-update-comment from 2 to 3

Bumps [peter-evans/create-or-update-comment](https://github.com/peter-evans/create-or-update-comment) from 2 to 3.
- [Release notes](https://github.com/peter-evans/create-or-update-comment/releases)
- [Commits](peter-evans/create-or-update-comment@v2...v3)

---
updated-dependencies:
- dependency-name: peter-evans/create-or-update-comment
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>

* Update changelog

Signed-off-by: dependabot[bot] <[email protected]>

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Signed-off-by: Kaushal Kumar <[email protected]>
* Bump actions/checkout from 2 to 4

Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v2...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>

* Update changelog

Signed-off-by: dependabot[bot] <[email protected]>

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Signed-off-by: Kaushal Kumar <[email protected]>
Update changelog.

Signed-off-by: Austin Lee <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
Signed-off-by: Kaushal Kumar <[email protected]>
@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@stephen-crawford
Copy link
Contributor

Please rebase--this says 331 commits are involved with this change. Thank you

@kaushalmahi12
Copy link
Contributor Author

Closing this PR in favor of #10028 due to DCO validation failure in a past commit.

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.