Skip to content
This repository has been archived by the owner on Feb 28, 2024. It is now read-only.

add metrics crate #48

Merged
merged 7 commits into from Feb 4, 2022
Merged

add metrics crate #48

merged 7 commits into from Feb 4, 2022

Conversation

rc-andres
Copy link
Collaborator

follow-up from: #47

This lets users of oxidebpf to optionally elect into receiving metrics via the metrics crate for size of the mmap and how filled it is right before being read. This should let users of oxidebpf determine how their perf buffers are being used. In the future we may add more metrics under the same feature flag.

Base automatically changed from add-metrics to main February 4, 2022 19:17
@rc-andres rc-andres marked this pull request as ready for review February 4, 2022 21:14
go back to 2018 edition because the metrics macros don't seem to be
working on Rust 2021
Copy link
Contributor

@FridayOrtiz FridayOrtiz left a comment

Choose a reason for hiding this comment

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

Do we need to list this as a feature?

[features]
log_buf = []
rootless_blueprints = []
metrics = []

There's also a CI issue re: 2018 vs 2021 edition.

Cargo.toml Outdated Show resolved Hide resolved
@FridayOrtiz FridayOrtiz self-requested a review February 4, 2022 21:36
Copy link
Contributor

@FridayOrtiz FridayOrtiz left a comment

Choose a reason for hiding this comment

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

This is going to be super helpful!

README.md Outdated Show resolved Hide resolved
src/maps/mod.rs Outdated Show resolved Hide resolved
Copy link

@pinealservo pinealservo left a comment

Choose a reason for hiding this comment

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

Looking good, aside from a minor nit about a comment.

metrics works in this edition if syn is added as a build dependency
@rc-andres rc-andres merged commit d2f2ca3 into main Feb 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants