Skip to content

Commit

Permalink
propagate trace to EOS
Browse files Browse the repository at this point in the history
  • Loading branch information
labkode committed Feb 8, 2024
1 parent ce0bd1e commit 488b4da
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 328 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,5 @@ tests/ocis/tests/acceptance/work_tmp
.air.toml

toolchain/

logs_test/
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ require (
github.com/wk8/go-ordered-map v1.0.0
go-micro.dev/v4 v4.3.1-0.20211108085239-0c2041e43908
go.opencensus.io v0.24.0
go.opentelemetry.io/otel/trace v1.20.0
go.step.sm/crypto v0.39.0
golang.org/x/crypto v0.17.0
golang.org/x/oauth2 v0.14.0
Expand Down Expand Up @@ -142,6 +141,7 @@ require (
go.etcd.io/bbolt v1.3.8 // indirect
go.mongodb.org/mongo-driver v1.11.3 // indirect
go.opentelemetry.io/otel v1.20.0 // indirect
go.opentelemetry.io/otel/trace v1.20.0 // indirect
golang.org/x/mod v0.13.0 // indirect
golang.org/x/net v0.19.0 // indirect
golang.org/x/time v0.5.0 // indirect
Expand Down
324 changes: 0 additions & 324 deletions logs_tests

This file was deleted.

5 changes: 2 additions & 3 deletions pkg/eosclient/eosbinary/eosbinary.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ import (
"github.com/cs3org/reva/pkg/eosclient"
"github.com/cs3org/reva/pkg/errtypes"
"github.com/cs3org/reva/pkg/storage/utils/acl"
"github.com/cs3org/reva/pkg/trace"
"github.com/google/uuid"
"github.com/pkg/errors"
"go.opentelemetry.io/otel/trace"
)

const (
Expand Down Expand Up @@ -243,8 +243,7 @@ func (c *Client) executeEOS(ctx context.Context, cmdArgs []string, auth eosclien

cmd.Args = append(cmd.Args, cmdArgs...)

span := trace.SpanFromContext(ctx)
cmd.Args = append(cmd.Args, "--comment", span.SpanContext().TraceID().String())
cmd.Args = append(cmd.Args, "--comment", trace.Get(ctx))

err := cmd.Run()

Expand Down

0 comments on commit 488b4da

Please sign in to comment.