-
Notifications
You must be signed in to change notification settings - Fork 384
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add logs and metrics to default features in api, sdk and otlp crate (#…
- Loading branch information
1 parent
29ac005
commit 79189a8
Showing
7 changed files
with
21 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
# Log Appender for API - Example | ||
# OpenTelemetry Log Appender for log - Example | ||
|
||
This example shows how to use the opentelemetry-appender-log crate, which is a | ||
[logging appender](https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/glossary.md#log-appender--bridge) that bridges logs from the [log crate](https://docs.rs/log/latest/log/) to OpenTelemetry. | ||
The example setups a LoggerProvider with stdout exporter, so logs are emitted to stdout. | ||
[logging | ||
appender](https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/glossary.md#log-appender--bridge) | ||
that bridges logs from the [log crate](https://docs.rs/log/latest/log/) to | ||
OpenTelemetry. The example setups a LoggerProvider with stdout exporter, so logs | ||
are emitted to stdout. | ||
|
||
## Usage | ||
|
||
Run the following, and Logs emitted using [log](https://docs.rs/log/latest/log/) will be written out to stdout. | ||
Run the following, and Logs emitted using [log](https://docs.rs/log/latest/log/) | ||
will be written out to stdout. | ||
|
||
```shell | ||
$ cargo run | ||
cargo run | ||
``` | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters