-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move Go website_docs into opentelemetry.io repo (#2872)
Co-authored-by: Severin Neumann <neumanns@cisco.com> Co-authored-by: Phillip Carter <pcarter@fastmail.com>
- Loading branch information
1 parent
4c873f2
commit a6a6b30
Showing
15 changed files
with
1,281 additions
and
53 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
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
Submodule opentelemetry-go
deleted from
4f4815
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
title: Go | ||
description: >- | ||
<img width="35" class="img-initial" src="/img/logos/32x32/Golang_SDK.svg" | ||
alt="Go"></img> A language-specific implementation of OpenTelemetry in Go. | ||
aliases: [/golang, /golang/metrics, /golang/tracing] | ||
weight: 16 | ||
--- | ||
|
||
{{% docs/instrumentation/index-intro go /%}} | ||
|
||
## More | ||
|
||
- [Contrib repository](https://github.com/open-telemetry/opentelemetry-go-contrib) |
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
--- | ||
title: API reference | ||
linkTitle: API | ||
redirect: https://pkg.go.dev/go.opentelemetry.io/otel | ||
manualLinkTarget: _blank | ||
_build: { render: link } | ||
weight: 210 | ||
--- |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
title: Examples | ||
redirect: https://github.com/open-telemetry/opentelemetry-go/tree/main/example | ||
manualLinkTarget: _blank | ||
_build: { render: link } | ||
weight: 220 | ||
--- |
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 |
---|---|---|
@@ -0,0 +1,57 @@ | ||
--- | ||
title: Exporters | ||
aliases: [/docs/instrumentation/go/exporting_data] | ||
weight: 50 | ||
--- | ||
|
||
In order to visualize and analyze your [traces](/docs/concepts/signals/traces/) | ||
and metrics, you will need to export them to a backend. | ||
|
||
## OTLP endpoint | ||
|
||
To send trace data to an OTLP endpoint (like the [collector](/docs/collector) or | ||
Jaeger >= v1.35.0) you'll want to configure an OTLP exporter that sends to your | ||
endpoint. | ||
|
||
### Using HTTP | ||
|
||
```go | ||
import ( | ||
"go.opentelemetry.io/otel/exporters/otlp/otlptrace" | ||
"go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp" | ||
) | ||
|
||
func installExportPipeline(ctx context.Context) (func(context.Context) error, error) { | ||
client := otlptracehttp.NewClient() | ||
exporter, err := otlptrace.New(ctx, client) | ||
if err != nil { | ||
return nil, fmt.Errorf("creating OTLP trace exporter: %w", err) | ||
} | ||
/* … */ | ||
} | ||
``` | ||
|
||
To learn more on how to use the OTLP HTTP exporter, try out the | ||
[otel-collector](https://github.com/open-telemetry/opentelemetry-go/tree/main/example/otel-collector) | ||
|
||
### Jaeger | ||
|
||
To try out the OTLP exporter, since v1.35.0 you can run | ||
[Jaeger](https://www.jaegertracing.io/) as an OTLP endpoint and for trace | ||
visualization in a docker container: | ||
|
||
```shell | ||
docker run -d --name jaeger \ | ||
-e COLLECTOR_OTLP_ENABLED=true \ | ||
-p 16686:16686 \ | ||
-p 4318:4318 \ | ||
jaegertracing/all-in-one:latest | ||
``` | ||
|
||
## Prometheus | ||
|
||
Prometheus export is available in the | ||
`go.opentelemetry.io/otel/exporters/prometheus` package. | ||
|
||
Please find more documentation on | ||
[GitHub](https://github.com/open-telemetry/opentelemetry-go/tree/main/exporters/prometheus) |
Oops, something went wrong.