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

Health Metrics for data-pipeline + Dogstatsd-Client Crate #638

Open
wants to merge 45 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
75ecb44
move dogstatsd-client to separate crate so it can be shared
ajgajg1134 Sep 9, 2024
ba57b1d
adding some initial stats and tests
ajgajg1134 Sep 10, 2024
581c243
make traceexporter mut
ajgajg1134 Sep 10, 2024
5746b4a
Merge branch 'main' into andrew.glaude/dogstatsd-client
ajgajg1134 Sep 11, 2024
7411f46
miri can ignore unit test
ajgajg1134 Sep 11, 2024
fe3cc6d
Merge branch 'main' into andrew.glaude/dogstatsd-client
ajgajg1134 Sep 11, 2024
6515250
refactor dogstatsd-client to not need mutability
ajgajg1134 Sep 12, 2024
a388c80
use vec default to avoid unneeded allocation
ajgajg1134 Sep 12, 2024
dfb1e51
fmt
ajgajg1134 Sep 12, 2024
77bfbd2
Merge branch 'main' into andrew.glaude/dogstatsd-client
ajgajg1134 Sep 12, 2024
062a891
add dogstatsd-client to docker build tool
ajgajg1134 Sep 12, 2024
d9d21ee
clean up cargo.toml
ajgajg1134 Sep 12, 2024
61d5f83
remove unneeded dep
ajgajg1134 Sep 12, 2024
0bb2986
use AsRef for metric strings, improve perf and simplify usage
ajgajg1134 Sep 12, 2024
2961334
simplify emitting stats in data-pipeline
ajgajg1134 Sep 12, 2024
b0b0256
fix lint
ajgajg1134 Sep 12, 2024
2f65946
Remove copy of tags and pass to dogstatsd client by reference
ajgajg1134 Sep 13, 2024
4d25dc2
Update licenses
ajgajg1134 Sep 13, 2024
37fd00e
Allow IntoIterator tags to support static and dynamic tags: WIP
ajgajg1134 Sep 13, 2024
ad04e27
Fix lifetimes of DogstatsDAction
bwoebi Sep 17, 2024
d30df06
Actually also allow &Vec<Tag> and &[Tag]
bwoebi Sep 17, 2024
242224c
cargo fmt
ajgajg1134 Sep 17, 2024
93f6cb6
disable cargo bench in dogstatd-client, we use criterion
ajgajg1134 Sep 17, 2024
5532b66
Merge branch 'main' into andrew.glaude/dogstatsd-client
ajgajg1134 Sep 17, 2024
8fecb9a
Try using iterators in data-pipeline for metrics
ajgajg1134 Sep 17, 2024
1141243
bump ver
ajgajg1134 Sep 18, 2024
ab002f5
more metrics
ajgajg1134 Sep 18, 2024
aef310a
Split dogstatsdaction type to simplify code
ajgajg1134 Sep 18, 2024
1cb870a
move to owned type for sidecar-ffi
ajgajg1134 Sep 18, 2024
22b333d
remove unused import
ajgajg1134 Sep 18, 2024
88732cf
more unused
ajgajg1134 Sep 18, 2024
d7b6cd4
Add variant check
ajgajg1134 Sep 18, 2024
226f7ab
add test that fails when dogstatsdAction is updated
ajgajg1134 Sep 18, 2024
e4027aa
fix tests
ajgajg1134 Sep 18, 2024
7945997
use either to simplify emit_metric code
ajgajg1134 Sep 18, 2024
29a5f74
resolve todo
ajgajg1134 Sep 18, 2024
761ba8f
Add docs and initial PR review comments
ajgajg1134 Sep 19, 2024
65e9d93
more docs and readme
ajgajg1134 Sep 19, 2024
860000d
Merge branch 'main' into andrew.glaude/dogstatsd-client-SPLIT
ajgajg1134 Sep 19, 2024
844406a
add ticket for todo
ajgajg1134 Sep 19, 2024
ea71062
Merge branch 'main' into andrew.glaude/dogstatsd-client-SPLIT
ajgajg1134 Sep 20, 2024
9e78eef
PR comments
ajgajg1134 Sep 20, 2024
75b3269
remove unused import
ajgajg1134 Sep 20, 2024
70e191f
license header
ajgajg1134 Sep 20, 2024
3b0f6e4
Merge branch 'main' into andrew.glaude/dogstatsd-client-SPLIT
ajgajg1134 Sep 20, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 22 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ members = [
"data-pipeline-ffi",
"ddsketch",
"tinybytes",
"dogstatsd-client",
ajgajg1134 marked this conversation as resolved.
Show resolved Hide resolved
]

# https://doc.rust-lang.org/cargo/reference/resolver.html#feature-resolver-version-2
Expand Down
4 changes: 2 additions & 2 deletions LICENSE-3rdparty.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
root_name: datadog-alloc, builder, build_common, datadog-profiling-ffi, data-pipeline-ffi, data-pipeline, datadog-ddsketch, datadog-trace-normalization, datadog-trace-protobuf, datadog-trace-obfuscation, datadog-trace-utils, ddcommon, tinybytes, ddcommon-ffi, datadog-crashtracker-ffi, datadog-crashtracker, ddtelemetry, datadog-profiling, ddtelemetry-ffi, symbolizer-ffi, tools, datadog-profiling-replayer, dogstatsd, datadog-ipc, datadog-ipc-macros, tarpc, tarpc-plugins, spawn_worker, cc_utils, datadog-sidecar, datadog-remote-config, datadog-dynamic-configuration, datadog-sidecar-macros, datadog-sidecar-ffi, sidecar_mockgen, test_spawn_from_lib, datadog-serverless-trace-mini-agent, datadog-trace-mini-agent
root_name: datadog-alloc, builder, build_common, datadog-profiling-ffi, data-pipeline-ffi, data-pipeline, datadog-ddsketch, datadog-trace-normalization, datadog-trace-protobuf, datadog-trace-obfuscation, datadog-trace-utils, ddcommon, tinybytes, dogstatsd-client, ddcommon-ffi, datadog-crashtracker-ffi, datadog-crashtracker, ddtelemetry, datadog-profiling, ddtelemetry-ffi, symbolizer-ffi, tools, datadog-profiling-replayer, dogstatsd, datadog-ipc, datadog-ipc-macros, tarpc, tarpc-plugins, spawn_worker, cc_utils, datadog-sidecar, datadog-remote-config, datadog-dynamic-configuration, datadog-sidecar-macros, datadog-sidecar-ffi, sidecar_mockgen, test_spawn_from_lib, datadog-serverless-trace-mini-agent, datadog-trace-mini-agent
third_party_libraries:
- package_name: addr2line
package_version: 0.21.0
Expand Down Expand Up @@ -10338,7 +10338,7 @@ third_party_libraries:
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
- package_name: either
package_version: 1.10.0
package_version: 1.13.0
repository: https://github.com/rayon-rs/either
license: MIT OR Apache-2.0
licenses:
Expand Down
4 changes: 3 additions & 1 deletion data-pipeline/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,16 @@ hyper = {version = "0.14", features = ["client"], default-features = false}
log = "0.4"
rmp-serde = "1.1.1"
bytes = "1.4"
either = "1.13.0"
tokio = { version = "1.23", features = ["rt", "test-util", "time"], default-features = false }

ddcommon = { path = "../ddcommon" }
datadog-trace-protobuf = { path = "../trace-protobuf" }
datadog-trace-utils = { path = "../trace-utils" }
datadog-trace-normalization = { path = "../trace-normalization" }
datadog-ddsketch = { path = "../ddsketch"}
dogstatsd-client = { path = "../dogstatsd-client"}
datadog-trace-obfuscation = { path = "../trace-obfuscation" }
datadog-ddsketch = { path = "../ddsketch" }
uuid = { version = "1.10.0", features = ["v4"] }
tokio-util = "0.7.11"

Expand Down
14 changes: 14 additions & 0 deletions data-pipeline/src/health_metrics.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Copyright 2024-Present Datadog, Inc. https://www.datadoghq.com/
// SPDX-License-Identifier: Apache-2.0

/// health_metrics holds data to emit info about the health of the data-pipeline

pub(crate) const STAT_SEND_TRACES: &str = "datadog.libdatadog.send.traces";
pub(crate) const STAT_SEND_TRACES_ERRORS: &str = "datadog.libdatadog.send.traces.errors";
pub(crate) const STAT_DESER_TRACES: &str = "datadog.libdatadog.deser_traces";
pub(crate) const STAT_DESER_TRACES_ERRORS: &str = "datadog.libdatadog.deser_traces.errors";
pub(crate) const STAT_SER_TRACES_ERRORS: &str = "datadog.libdatadog.ser_traces.errors";

pub(crate) enum HealthMetric {
Count(&'static str, i64),
}
1 change: 1 addition & 0 deletions data-pipeline/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
//! project at this state is to provide a basic API in order to test its viability and integration
//! in different languages.

mod health_metrics;
#[allow(missing_docs)]
pub mod span_concentrator;
#[allow(missing_docs)]
Expand Down
Loading
Loading