Dom Dwyer
928a4d163e
build: remove unused dependencies from crates
...
This commit fixes loads of crates (47!) had unused dependencies, or
mis-configured dependencies (test deps as normal deps).
I added the "unused_crate_dependencies" to all crates to help prevent
this mess from growing again!
https://doc.rust-lang.org/beta/nightly-rustc/rustc_lint_defs/builtin/static.UNUSED_CRATE_DEPENDENCIES.html
This has the minor downside of false-positives when specifying
dev-dependencies for test/bench binaries - these are files in /test or
/benches (not normal tests). This commit includes a workaround,
importing them in lib.rs (gated by a feature flag). I think the
trade-off of better dependency management is worth it!
2023-05-23 14:55:43 +02:00
Dom Dwyer
45c8519a0b
refactor(metric): assert macro import scopes
...
The assert_counter! and assert_histogram! macros use items in the metric
crate, but the macros can be called from other crates/modules that may
not have those items in scope.
2023-03-15 15:10:37 +01:00
Carol (Nichols || Goulding)
05c3ca0f47
feat: Create a macro for testing counter metrics and use it
2023-03-08 15:52:46 -05:00
Carol (Nichols || Goulding)
38554f0b79
fix: Make assert_histogram macro more flexible
...
So you can use it when the metric name is in a constant rather than only
a literal.
2023-03-08 14:52:53 -05:00
Carol (Nichols || Goulding)
efdb7bf72d
refactor: Enable reuse of a metric test macro
2023-03-08 14:52:52 -05:00
Carol (Nichols || Goulding)
faae5eb438
chore: Rerun cargo hakari manage-deps
2023-02-27 11:56:15 +01:00
Carol (Nichols || Goulding)
30fea67701
fix: Move variables within format strings. Thanks clippy!
...
Changes made automatically using `cargo clippy --fix`.
2023-02-03 13:06:17 -05:00
Carol (Nichols || Goulding)
2e83e04eab
feat: Use workspace package metadata to reduce differences and repetition
2022-10-24 13:04:09 -04:00
Dom Dwyer
cd4087e00d
style: add no todo!() or dbg!() lints
...
Some crates had theme, some not - lets be consistent and have the
compiler spot dbg!() and todo!() macro calls - they should never be in
prod code!
2022-09-29 13:10:07 +02:00
Carol (Nichols || Goulding)
6f07b3f547
fix: Use unsigned_abs instead of casting abs to u64
2022-07-01 13:31:32 -04:00
Marco Neumann
f7fbc67b00
feat: extend duration histograms down to 1ms ( #4854 )
...
5ms are quite long considering that many requests take way below 100ms in
total. Let's add two more levels on the lower end of the spectrum.
Since we only do not use data-dependent histograms (i.e. do not include
table or namespace names), the overhead should be acceptable.
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2022-06-14 15:30:00 +00:00
Dom Dwyer
77f649210d
feat: inc/dec gauge metrics
...
Adds methods to increment, or decrement gauge metrics.
2022-02-24 15:04:49 +00:00
Marco Neumann
22778a3a80
chore: upgrade rskafka and parking_lot ( #3592 )
2022-02-01 11:50:42 +00:00
Carol (Nichols || Goulding)
b21ef26d24
fix: Convince Rust we're using a must_use value in a panicking test
2021-12-02 11:52:01 -05:00
Carol (Nichols || Goulding)
9fd4a560f5
feat: Results of running cargo hakari manage-deps
2021-11-19 09:21:57 -05:00
Marco Neumann
bc7244c48e
chore: use Rust edition 2021
2021-10-25 10:58:20 +02:00
Raphael Taylor-Davies
6f2301e16c
feat: migrate write buffer metrics ( #2536 )
...
* feat: migrate write buffer metrics
* feat: update server/src/write_buffer.rs
Co-authored-by: Andrew Lamb <alamb@influxdata.com>
Co-authored-by: Andrew Lamb <alamb@influxdata.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-15 17:41:55 +00:00
Raphael Taylor-Davies
f3bcafcfea
feat: migrate http metrics to metric crate ( #2508 )
...
* feat: migrate http metrics
* chore: review feedback
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-13 18:56:20 +00:00
Raphael Taylor-Davies
574149d644
feat: migrate remaining catalog metrics to new crate ( #2490 )
...
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-13 14:42:14 +00:00
Raphael Taylor-Davies
b8f7319704
feat: migrate read buffer metrics to metric crate ( #2510 )
...
* feat: migrate read buffer metrics to metric crate
* chore: review feedback
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-10 19:51:43 +00:00
Raphael Taylor-Davies
e5e68b1978
feat: add RecorderCollection ( #2494 )
...
* feat: add MetricRecorder
* chore: rename MetricRecorder to RecorderCollection
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-09 15:38:21 +00:00
Raphael Taylor-Davies
3cee899f77
feat: migrate catalog timestamp summary to `metric` crate ( #2486 )
...
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-09 14:52:25 +00:00
Raphael Taylor-Davies
9de12745e7
feat: migrate lock metrics to metric crate ( #2481 )
...
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-09 08:56:19 +00:00
Raphael Taylor-Davies
a4b0cbc0e7
feat: migrate jemalloc metrics to `metric` crate ( #2435 )
...
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-09-06 09:18:27 +00:00
Marco Neumann
79ad48ac3a
chore: rename "labels" to "attributes"
2021-08-31 11:31:15 +02:00
Raphael Taylor-Davies
fcec394a28
feat: connect up new metrics ( #2428 )
2021-08-27 12:55:35 +00:00
Raphael Taylor-Davies
3a26f7857f
feat: add new metrics abstraction ( #2076 ) ( #2365 )
...
* feat: add new metrics abstraction (#2076 )
* chore: fix lint
* feat: add tests
feat: histogram export
* chore: further docs
* chore: docs
* chore: log on prometheus export error
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-08-27 11:54:23 +00:00