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

Replace WithSyncer with WithBatcher in examples #1044

Merged
merged 3 commits into from
Aug 7, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
This removes the package dependencies of this bridge from the rest of the OpenTelemetry based project. (#1038)
- Renamed `go.opentelemetry.io/otel/api/standard` package to `go.opentelemetry.io/otel/semconv` to avoid the ambiguous and generic name `standard` and better describe the package as containing OpenTelemetry semantic conventions. (#1016)
- The environment variable used for resource detection has been changed from `OTEL_RESOURCE_LABELS` to `OTEL_RESOURCE_ATTRIBUTES` (#1042)
- Replace `WithSyncer` with `WithBatcher` in examples. (#1044)

### Removed

Expand Down
2 changes: 1 addition & 1 deletion example/namedtracer/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func initTracer() {
log.Panicf("failed to initialize stdout exporter %v\n", err)
return
}
tp, err = sdktrace.NewProvider(sdktrace.WithSyncer(exp),
tp, err = sdktrace.NewProvider(sdktrace.WithBatcher(exp),
sdktrace.WithConfig(sdktrace.Config{DefaultSampler: sdktrace.AlwaysSample()}))
if err != nil {
log.Panicf("failed to initialize trace provider %v\n", err)
Expand Down
2 changes: 1 addition & 1 deletion example/otel-collector/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func initProvider() (*otlp.Exporter, *push.Controller) {
// the service name used to display traces in backends
kv.Key(semconv.ServiceNameKey).String("test-service"),
)),
sdktrace.WithSyncer(exp),
sdktrace.WithBatcher(exp),
)
handleErr(err, "failed to create trace provider")

Expand Down
2 changes: 1 addition & 1 deletion exporters/otlp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func main() {
// sdktrace.WithMaxExportBatchSize(100),
// ),
// )
traceProvider, err := sdktrace.NewProvider(sdktrace.WithSyncer(exporter))
traceProvider, err := sdktrace.NewProvider(sdktrace.WithBatcher(exporter))
if err != nil {
log.Fatal("failed to create trace provider: %v", err)
}
Expand Down