-
Notifications
You must be signed in to change notification settings - Fork 0
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
DEV-1203: Additional ingest performance monitoring (collate/storage) #128
Conversation
f92443a
to
dc7507a
Compare
9b4e556
to
f7d2463
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See two comments, one on naming conventions and the other on tabs. Don't feel like making either an impediment to merging, though I think the naming convention is worth further thought/brainstorming.
@mwarin Have we looked at perltidy https://metacpan.org/pod/Perl::Tidy recently? It might be able to do some of these tidyings/reformattings automatically, although it looks like it has quite a few options... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall I think this is looking like a good approach. There are a couple things I'd like to see:
- labels for the storage name
- labels for the specific image remediate operation
- consider extracting the metrics recording stuff to a method to reduce duplication
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking in pretty good shape; I don't see anything I think needs to block merge, although there are a couple small things to potentially consider now and a few things I think we should note as issues for future work.
I did want to verify that although this PR adds support for labels on metrics, there aren't yet places we're using those labels -- correct?
This PR does the following changes to
JobMetrics
:JobMetrics
andJobMetricsCLI
, to simplify main class and not pollute it with CLI stuff.In most cases where monitoring is added, I've added some variation on:
... plus a matching metric declaration in
HTFeed::JobMetrics
.I've also added 2 convenience subs to
HTFeed::JobMetrics
:time
for providing high resolution timedir_size
for calculating the size of a directory... which are both data points that are often needed for measuring.
Reviewer info
I originally tried to separate and label commits thematically, but this started falling apart as the PR grew too large. There are some TIDY commits, a big FUNC commit with mostly additions (that nevertheless has some tidyings in it, discipline slipped), and a TEST commit. I will squash them all before merging.
Please check:
t/job_metrics.t
JobMetrics::_setup_metrics
Please be on the lookout for any log warnings about
WARN: invalid metric name "ingest_xxx_yyy"
, this is a sign that we are trying to record data for a metric that has not been declared inHTFeed::JobMetrics
.