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

Macpie/custom tracing #791

Merged
merged 47 commits into from
May 6, 2024
Merged

Macpie/custom tracing #791

merged 47 commits into from
May 6, 2024

Conversation

macpie
Copy link
Member

@macpie macpie commented Apr 19, 2024

  • Add a tracing_subscriber that is re-loadable via a file (takes the content of the file and turn it into an EnvFilter)
    • File can be created
    • File delete will go back to original filter from settings (same for empty file)
  • Gives negative feedback when file content cannot be parsed as an EnvFilter
  • Functions to create tracing spans around GRPC (tonic) or HTTP (axum) including latency
  • GRPC or HTTP are lib features
  • Include one example of use in ingest/server_mobile
  • Filter ex custom_tracing=info,mapper_ingestor[tracing{uri=/session_init}]

custom_tracing/src/lib.rs Outdated Show resolved Hide resolved
ingest/Cargo.toml Show resolved Hide resolved
custom_tracing/src/grpc_layer.rs Show resolved Hide resolved
custom_tracing/src/lib.rs Outdated Show resolved Hide resolved
custom_tracing/src/lib.rs Outdated Show resolved Hide resolved
custom_tracing/Cargo.toml Outdated Show resolved Hide resolved
custom_tracing/src/grpc_layer.rs Outdated Show resolved Hide resolved
ingest/src/settings.rs Outdated Show resolved Hide resolved
custom_tracing/src/lib.rs Outdated Show resolved Hide resolved
custom_tracing/src/lib.rs Outdated Show resolved Hide resolved
ingest/src/server_mobile.rs Outdated Show resolved Hide resolved
ingest/src/server_mobile.rs Outdated Show resolved Hide resolved
ingest/src/server_mobile.rs Outdated Show resolved Hide resolved
ingest/src/server_mobile.rs Outdated Show resolved Hide resolved
ingest/src/server_mobile.rs Outdated Show resolved Hide resolved
@jeffgrunewald
Copy link
Contributor

Since this custom tracing is spawning a process off is tokio respecting the shutdown signals from the thing that instantiates these being shutdown or do these need to be run underneath the task manager in order to shut down as expected with a ctrl-c?

@macpie
Copy link
Member Author

macpie commented May 1, 2024

Since this custom tracing is spawning a process off is tokio respecting the shutdown signals from the thing that instantiates these being shutdown or do these need to be run underneath the task manager in order to shut down as expected with a ctrl-c?

Yes I made sure it does

@macpie macpie merged commit d29595c into main May 6, 2024
1 check passed
@macpie macpie deleted the macpie/custom-tracing branch May 6, 2024 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants