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

Prometheus metrics #436

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

msiebuhr
Copy link

@msiebuhr msiebuhr commented Sep 27, 2022

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:
    • Ran into obviously dead code, which I removed.

The PR fulfills these requirements:

  • All tests are passing?
  • New/updated tests are included?
  • If any static assets have been updated, has ui/bindata.go been regenerated?
  • Are there doc blocks for functions that I updated/created?

If adding a new feature, the PR's description includes:
Adds some simple Prometheus metrics for tracking a few important bits of Hound:

  • How many searches are done (touches How to track usage of Hound #295) and approx. speed (we can't measure user round-trip time)
  • Some rough data on how the underlying indices are performing with individual timings and number of touched files.
  • I'm playing with hound at $WORK, and not having metrics feels a bit ... weird. So fixing Add prometheus metrics #410...

I've tried to choose metrics that give an indication of user-observed
latency _and_ some internal metrics on how each index is performing.

The latter metrics should probably me massaged into the search-module,
but there it doesn't seem to know it's own name, which complicates
things. (Our git-link has secrets embedded, so I won't use those).

I don't know if metrics on number of returned results would be
meaningful, as we can't tune what the users are searching for anyway.
@msiebuhr msiebuhr changed the title Msiebuhr/cleanup Prometheus metrics Sep 27, 2022
@msiebuhr
Copy link
Author

Updated PR with configurable metrics endpoint.

@msiebuhr
Copy link
Author

And now with some rough API-docs.

@msiebuhr
Copy link
Author

This turned into a grab-bag of various bits; feel free to cherry-pick / fixup what you feel like (though I'd still love to see Prometheus metrics in there).

@Birdza87
Copy link

.

@Birdza87
Copy link

1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants