Skip to content

Commit

Permalink
fix: OpenTelemetry support on storage.
Browse files Browse the repository at this point in the history
  • Loading branch information
gfyrag committed Jul 15, 2022
1 parent 9d99d62 commit a100783
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 8 deletions.
32 changes: 32 additions & 0 deletions examples/jaeger-exporter/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
volumes:
postgres:
services:
postgres:
extends:
file: ../../docker-compose.yml
service: postgres
jaeger:
image: jaegertracing/opentelemetry-all-in-one
ports:
- "16686:16686/tcp"
ledger:
extends:
file: ../../docker-compose.yml
service: ledger
depends_on:
- postgres
- jaeger
image: golang:1.18-alpine
entrypoint: go run main.go server start
volumes:
- ../..:/src
working_dir: /src
ports:
- "3068:3068/tcp"
environment:
CGO_ENABLED: 0
NUMARY_DEBUG: "true"
NUMARY_OTEL_TRACES: "true"
NUMARY_OTEL_TRACES_EXPORTER: jaeger
NUMARY_OTEL_TRACES_EXPORTER_JAEGER_ENDPOINT: http://jaeger:14268/api/traces
8 changes: 0 additions & 8 deletions pkg/ledger/resolver.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,6 @@ func (fn ResolveOptionFn) apply(r *Resolver) error {
return fn(r)
}

func WithStorageDriver(factory storage.Driver) ResolveOptionFn {
return func(r *Resolver) error {
r.storageDriver = factory
return nil
}
}

func WithLocker(locker Locker) ResolveOptionFn {
return func(r *Resolver) error {
r.locker = locker
Expand Down Expand Up @@ -108,7 +101,6 @@ func ResolveModule() fx.Option {
fx.Provide(
fx.Annotate(NewResolver, fx.ParamTags("", ResolverOptionsKey)),
),
ProvideResolverOption(WithStorageDriver),
)
}

Expand Down

0 comments on commit a100783

Please sign in to comment.