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 PuppetDB Jetty thread metrics #103

Merged
merged 1 commit into from
Jun 2, 2021

Conversation

jarretlavallee
Copy link
Contributor

@jarretlavallee jarretlavallee commented Jun 1, 2021

Prior to this PR, there were no metrics around the jetty thread
pool. This PR adds additional metrics to collect the jetty
queuedthreadpool metrics. This allows for looking at the jetty thread
usage in PuppetDB.

Example:

                "jetty-queuedthreadpool": {
                    "org.eclipse.jetty.util.thread:id=0,type=queuedthreadpool": {
                        "availableReservedThreads": 2,
                        "busyThreads": 7,
                        "daemon": false,
                        "detailedDump": false,
                        "idleThreads": 1,
                        "idleTimeout": 60000,
                        "leasedThreads": 6,
                        "lowOnThreads": false,
                        "lowThreadsThreshold": 1,
                        "maxAvailableThreads": 194,
                        "maxLeasedThreads": 10,
                        "maxReservedThreads": 4,
                        "maxThreads": 200,
                        "minThreads": 8,
                        "name": "qtp1512214559",
                        "queueSize": 0,
                        "readyThreads": 3,
                        "reservedThreads": -1,
                        "state": "STARTED",
                        "stopTimeout": 30000,
                        "threads": 10,
                        "threadsPriority": 5,
                        "utilizationRate": 0.005154639175257732,
                        "utilizedThreads": 1
                    }
                },

Prior to this commit, there were no metrics around the jetty thread
pool. This commit adds additional metrics to collect the jetty
queuedthreadpool metrics. This allows for looking at the jetty thread
usage in PuppetDB.
@jarretlavallee jarretlavallee requested a review from a team as a code owner June 1, 2021 20:58
@puppet-community-rangefinder
Copy link

puppet_metrics_collector::service::puppetdb is a class

that may have no external impact to Forge modules.

This module is declared in 0 of 576 indexed public Puppetfiles.


These results were generated with Rangefinder, a tool that helps predict the downstream impact of breaking changes to elements used in Puppet modules. You can run this on the command line to get a full report.

Exact matches are those that we can positively identify via namespace and the declaring modules' metadata. Non-namespaced items, such as Puppet 3.x functions, will always be reported as near matches only.

Copy link
Contributor

@MartyEwings MartyEwings left a comment

Choose a reason for hiding this comment

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

tested in my 2021.1 box new metric available

 },
        "jetty-queuedthreadpool": {
          "org.eclipse.jetty.util.thread:id=0,type=queuedthreadpool": {
            "threadsPriority": 5,
            "lowOnThreads": false,
            "queueSize": 0,
            "availableReservedThreads": 3,
            "stopTimeout": 30000,
            "utilizedThreads": 1,
            "utilizationRate": 0.005154639175257732,
            "minThreads": 8,
            "detailedDump": false,
            "maxReservedThreads": 4,
            "threads": 40,
            "reservedThreads": -1,
            "readyThreads": 33,
            "leasedThreads": 6,
            "daemon": false,
            "maxAvailableThreads": 194,
            "busyThreads": 7,
            "lowThreadsThreshold": 1,
            "idleTimeout": 60000,
            "name": "qtp2004632949",
            "idleThreads": 30,
            "state": "STARTED",
            "maxThreads": 200,
            "maxLeasedThreads": 10
          }

Unable to see anything broken

@jarretlavallee jarretlavallee merged commit db208cc into puppetlabs:main Jun 2, 2021
@jarretlavallee jarretlavallee deleted the jetty_threads branch June 2, 2021 14:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants