saatchibhalla opened a new pull request #2040:
URL: https://github.com/apache/lucene-solr/pull/2040


   <!--
   _(If you are a project committer then you may remove some/all of the 
following template.)_
   
   Before creating a pull request, please file an issue in the ASF Jira system 
for Lucene or Solr:
   
   * https://issues.apache.org/jira/projects/LUCENE
   * https://issues.apache.org/jira/projects/SOLR
   
   You will need to create an account in Jira in order to create an issue.
   
   The title of the PR should reference the Jira issue number in the form:
   
   * LUCENE-####: <short description of problem or changes>
   * SOLR-####: <short description of problem or changes>
   
   LUCENE and SOLR must be fully capitalized. A short description helps people 
scanning pull requests for items they can work on.
   
   Properly referencing the issue in the title ensures that Jira is correctly 
updated with code review comments and commits. -->
   
   
   # Description
   
   Please provide a short description of the changes you're making with this 
pull request.
   
   The Overseer work queues stored in ZK and abstracted by the Overseer can 
give us a good indication of the health of the cluster - if messages are taking 
too long to dequeue or the queue is growing too large, we know that the 
Overseer is overloaded and we are going to overwhelm the cluster.
   
   This work adds metrics to track the size of the Overseer queues 
(ClusterStateUpdate queue and Collections Work Queue).  
   
   # Solution
   
   Please provide a short description of the approach taken to implement your 
solution.
   
   Registered these two size metrics in a shared metrics registry for the 
Overseer. The Overseer shared metrics registry is only initialized upon 
reference so this shouldn't have any impact on metrics when run in non-cloud 
mode. Also updated the local solr-exporter-config.xml so that these metrics are 
exported and can be viewed locally in Grafana. 
   
   # Tests
   
   Please describe the tests you've developed or run to confirm this patch 
implements the feature or solves the problem.
   
   Local testing was accomplished by sending CreateCollection load and 
monitoring a local grafana dashboard which accessed the metrics through 
prometheus-exporter. As the size of these queues change extremely quickly, it 
was difficult to see changes in these metrics quickly enough--and if the 
requests were sent too quickly we'd see local solr hosts OOMing. However, I was 
able to verify that the metrics are updating as the size of the queues change, 
and in a real environment with more sustained load we should see these metrics 
more accurately represent the state of the Overseer.
   
   Testing confirmed that we don't see the Overseer metrics registry in 
non-cloud mode.
   
   **/admin/metrics response containing added metrics**
   <img width="298" alt="Screen Shot 2020-10-27 at 5 56 48 PM" 
src="https://user-images.githubusercontent.com/16807693/97367278-32600980-187f-11eb-98b5-98a321c0f5c9.png";>
   
   **local testing sending CreateCollection request load and seeing metrics 
update in real time**
   
![image](https://user-images.githubusercontent.com/16807693/97367388-5d4a5d80-187f-11eb-8c45-58abb0b0e0cc.png)
   
   
   
   # Checklist
   
   Please review the following and check all that apply:
   
   - [x] I have reviewed the guidelines for [How to 
Contribute](https://wiki.apache.org/solr/HowToContribute) and my code conforms 
to the standards described there to the best of my ability.
   - [x] I have created a Jira issue and added the issue ID to my pull request 
title.
   - [x] I have given Solr maintainers 
[access](https://help.github.com/en/articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork)
 to contribute to my PR branch. (optional but recommended)
   - [x] I have developed this patch against the `master` branch.
   - [x] I have run `./gradlew check`.
   - [ ] I have added tests for my changes.
   - [x] I have added documentation for the [Ref 
Guide](https://github.com/apache/lucene-solr/tree/master/solr/solr-ref-guide) 
(for Solr changes only).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to