Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
5 changes: 4 additions & 1 deletion build-index/cmd/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import (
"github.com/uber/kraken/utils/log"

"github.com/uber-go/tally"
"go.opentelemetry.io/otel"
"go.uber.org/zap"
)

Expand Down Expand Up @@ -215,6 +216,7 @@ func Run(flags *Flags, opts ...Option) {
if err != nil {
log.Fatalf("Error creating tag type manager: %s", err)
}
tracer := otel.Tracer("kraken-build-index")

server := tagserver.New(
config.TagServer,
Expand All @@ -227,7 +229,8 @@ func Run(flags *Flags, opts ...Option) {
remotes,
tagReplicationManager,
tagclient.NewProvider(tls),
depResolver)
depResolver,
tracer)
go func() {
log.Fatal(server.ListenAndServe())
}()
Expand Down
93 changes: 62 additions & 31 deletions build-index/tagserver/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
package tagserver

import (
"context"
"encoding/json"
"fmt"
"io"
Expand Down Expand Up @@ -44,6 +45,10 @@ import (
"github.com/go-chi/chi"
chimiddleware "github.com/go-chi/chi/middleware"
"github.com/uber-go/tally"
"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/trace"
)

// Server provides tag operations for the build-index.
Expand All @@ -63,6 +68,8 @@ type Server struct {

// For checking if a tag has all dependent blobs.
depResolver tagtype.DependencyResolver

tracer trace.Tracer
}

// New creates a new Server.
Expand All @@ -78,6 +85,7 @@ func New(
tagReplicationManager persistedretry.Manager,
provider tagclient.Provider,
depResolver tagtype.DependencyResolver,
tracer trace.Tracer,
) *Server {
config = config.applyDefaults()

Expand All @@ -97,6 +105,7 @@ func New(
tagReplicationManager: tagReplicationManager,
provider: provider,
depResolver: depResolver,
tracer: tracer,
}
}

Expand All @@ -109,8 +118,12 @@ func (s *Server) Handler() http.Handler {

r.Get("/health", handler.Wrap(s.healthHandler))
r.Get("/readiness", handler.Wrap(s.readinessCheckHandler))
tracingMiddleware := otelhttp.NewMiddleware("kraken-build-index",
otelhttp.WithTracerProvider(otel.GetTracerProvider()))

// Docker push endpoint
r.With(tracingMiddleware).Put("/tags/{tag}/digest/{digest}", handler.Wrap(s.putTagHandler))

r.Put("/tags/{tag}/digest/{digest}", handler.Wrap(s.putTagHandler))
r.Head("/tags/{tag}", handler.Wrap(s.hasTagHandler))
r.Get("/tags/{tag}", handler.Wrap(s.getTagHandler))

Expand Down Expand Up @@ -170,44 +183,62 @@ func (s *Server) readinessCheckHandler(w http.ResponseWriter, r *http.Request) e
}

func (s *Server) putTagHandler(w http.ResponseWriter, r *http.Request) error {
ctx, span := s.tracer.Start(r.Context(), "build_index.put_tag")
defer span.End()

tag, err := httputil.ParseParam(r, "tag")
if err != nil {
span.RecordError(err)
return err
}
d, err := httputil.ParseDigest(r, "digest")
if err != nil {
span.RecordError(err)
return err
}
replicate, err := strconv.ParseBool(httputil.GetQueryArg(r, "replicate", "false"))
if err != nil {
span.RecordError(err)
return fmt.Errorf("parse query arg `replicate`: %w", err)
}

log.With("tag", tag, "digest", d.String(), "replicate", replicate).Info("Putting tag")
span.SetAttributes(
attribute.String("tag", tag),
attribute.String("digest", d.String()),
attribute.Bool("replicate", replicate),
)

log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "replicate", replicate).Info("Putting tag")

deps, err := s.depResolver.Resolve(tag, d)
if err != nil {
log.With("tag", tag, "digest", d.String(), "error", err).Error("Failed to resolve dependencies")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "error", err).Error("Failed to resolve dependencies")
span.RecordError(err)
return fmt.Errorf("resolve dependencies: %w", err)
}

log.With("tag", tag, "digest", d.String(), "dependency_count", len(deps)).Debug("Resolved dependencies")
span.SetAttributes(attribute.Int("dependency_count", len(deps)))
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "dependency_count", len(deps)).Debug("Resolved dependencies")

if err := s.putTag(tag, d, deps); err != nil {
log.With("tag", tag, "digest", d.String(), "error", err).Error("Failed to put tag")
if err := s.putTag(ctx, tag, d, deps); err != nil {
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "error", err).Error("Failed to put tag")
span.RecordError(err)
return err
}

log.With("tag", tag, "digest", d.String()).Info("Successfully put tag")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String()).Info("Successfully put tag")

if replicate {
log.With("tag", tag, "digest", d.String()).Info("Starting tag replication")
if err := s.replicateTag(tag, d, deps); err != nil {
log.With("tag", tag, "digest", d.String(), "error", err).Error("Failed to replicate tag")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String()).Info("Starting tag replication")
if err := s.replicateTag(ctx, tag, d, deps); err != nil {
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "error", err).Error("Failed to replicate tag")
span.RecordError(err)
return err
}
log.With("tag", tag, "digest", d.String()).Info("Successfully replicated tag")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String()).Info("Successfully replicated tag")
}

span.SetAttributes(attribute.Bool("success", true))
w.WriteHeader(http.StatusOK)
return nil
}
Expand Down Expand Up @@ -409,7 +440,7 @@ func (s *Server) replicateTagHandler(w http.ResponseWriter, r *http.Request) err

log.With("tag", tag, "digest", d.String(), "dependency_count", len(deps)).Debug("Resolved dependencies for replication")

if err := s.replicateTag(tag, d, deps); err != nil {
if err := s.replicateTag(r.Context(), tag, d, deps); err != nil {
log.With("tag", tag, "digest", d.String()).Errorf("Failed to replicate tag: %s", err)
return err
}
Expand Down Expand Up @@ -461,8 +492,8 @@ func (s *Server) getOriginHandler(w http.ResponseWriter, r *http.Request) error
return nil
}

func (s *Server) putTag(tag string, d core.Digest, deps core.DigestList) error {
log.With("tag", tag, "digest", d.String(), "dependency_count", len(deps)).Debug("Validating tag dependencies")
func (s *Server) putTag(ctx context.Context, tag string, d core.Digest, deps core.DigestList) error {
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "dependency_count", len(deps)).Debug("Validating tag dependencies")

for _, dep := range deps {
if _, err := s.localOriginClient.Stat(tag, dep); err == blobclient.ErrBlobNotFound {
Expand All @@ -472,84 +503,84 @@ func (s *Server) putTag(tag string, d core.Digest, deps core.DigestList) error {
}
}

log.With("tag", tag, "digest", d.String()).Debug("All dependencies validated successfully")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String()).Debug("All dependencies validated successfully")

if err := s.store.Put(tag, d, 0); err != nil {
return fmt.Errorf("storage: %w", err)
}

log.With("tag", tag, "digest", d.String()).Info("Tag stored locally")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String()).Info("Tag stored locally")

neighbors := s.neighbors.Resolve()
neighborCount := len(neighbors)

log.With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Debug("Starting neighbor replication")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Debug("Starting neighbor replication")

var delay time.Duration
var successes int
for addr := range neighbors {
delay += s.config.DuplicatePutStagger
client := s.provider.Provide(addr)
if err := client.DuplicatePut(tag, d, delay); err != nil {
log.With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay, "error", err).Error("Failed to duplicate put to neighbor")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay, "error", err).Error("Failed to duplicate put to neighbor")
} else {
successes++
log.With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay).Debug("Successfully duplicated put to neighbor")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay).Debug("Successfully duplicated put to neighbor")
}
}

log.With("tag", tag, "digest", d.String(), "total_neighbors", neighborCount, "successful_neighbors", successes, "failed_neighbors", neighborCount-successes).Info("Completed neighbor replication")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "total_neighbors", neighborCount, "successful_neighbors", successes, "failed_neighbors", neighborCount-successes).Info("Completed neighbor replication")

if len(neighbors) != 0 && successes == 0 {
s.stats.Counter("duplicate_put_failures").Inc(1)
log.With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Error("All neighbor replications failed")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Error("All neighbor replications failed")
}
return nil
}

func (s *Server) replicateTag(tag string, d core.Digest, deps core.DigestList) error {
func (s *Server) replicateTag(ctx context.Context, tag string, d core.Digest, deps core.DigestList) error {
destinations := s.remotes.Match(tag)

log.With("tag", tag, "digest", d.String(), "destination_count", len(destinations)).Debug("Checking remote destinations for tag replication")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "destination_count", len(destinations)).Debug("Checking remote destinations for tag replication")

if len(destinations) == 0 {
log.With("tag", tag, "digest", d.String()).Debug("No remote destinations configured for tag")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String()).Debug("No remote destinations configured for tag")
return nil
}

log.With("tag", tag, "digest", d.String(), "destinations", destinations).Info("Adding remote replication tasks")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "destinations", destinations).Info("Adding remote replication tasks")

for _, dest := range destinations {
task := tagreplication.NewTask(tag, d, deps, dest, 0)
if err := s.tagReplicationManager.Add(task); err != nil {
return fmt.Errorf("add replicate task: %w", err)
}
log.With("tag", tag, "digest", d.String(), "destination", dest).Debug("Added remote replication task")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "destination", dest).Debug("Added remote replication task")
}

neighbors := s.neighbors.Resolve()
neighborCount := len(neighbors)

log.With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Debug("Notifying neighbors about remote replication")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Debug("Notifying neighbors about remote replication")

var delay time.Duration
var successes int
for addr := range neighbors { // Loops in random order.
delay += s.config.DuplicateReplicateStagger
client := s.provider.Provide(addr)
if err := client.DuplicateReplicate(tag, d, deps, delay); err != nil {
log.With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay).Errorf("Failed to notify neighbor about replication: %s", err)
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay).Errorf("Failed to notify neighbor about replication: %s", err)
} else {
successes++
log.With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay).Debug("Successfully notified neighbor about replication")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor", addr, "delay", delay).Debug("Successfully notified neighbor about replication")
}
}

log.With("tag", tag, "digest", d.String(), "remote_destinations", len(destinations), "notified_neighbors", successes, "failed_neighbors", neighborCount-successes).Info("Completed remote replication setup")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "remote_destinations", len(destinations), "notified_neighbors", successes, "failed_neighbors", neighborCount-successes).Info("Completed remote replication setup")

if len(neighbors) != 0 && successes == 0 {
s.stats.Counter("duplicate_replicate_failures").Inc(1)
log.With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Error("All neighbor replication notifications failed")
log.WithTraceContext(ctx).With("tag", tag, "digest", d.String(), "neighbor_count", neighborCount).Error("All neighbor replication notifications failed")
}
return nil
}
Expand Down
4 changes: 3 additions & 1 deletion build-index/tagserver/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ import (
mockblobclient "github.com/uber/kraken/mocks/origin/blobclient"
"github.com/uber/kraken/utils/httputil"
"github.com/uber/kraken/utils/testutil"
"go.opentelemetry.io/otel/trace/noop"
)

const (
Expand Down Expand Up @@ -125,7 +126,8 @@ func (m *serverMocks) handler() http.Handler {
m.remotes,
m.tagReplicationManager,
m.provider,
m.depResolver).Handler()
m.depResolver,
noop.NewTracerProvider().Tracer("test")).Handler()
}

func newClusterClient(addr string) tagclient.Client {
Expand Down
9 changes: 8 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,12 @@ require (
github.com/pressly/goose v2.6.0+incompatible
github.com/satori/go.uuid v1.2.0
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72
github.com/stretchr/testify v1.7.4
github.com/stretchr/testify v1.8.4
github.com/uber-go/tally v3.3.11+incompatible
github.com/willf/bitset v0.0.0-20190228212526-18bd95f470f9
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.0
go.opentelemetry.io/otel v1.21.0
go.opentelemetry.io/otel/trace v1.21.0
go.uber.org/atomic v1.5.0
go.uber.org/zap v1.10.0
golang.org/x/net v0.41.0
Expand Down Expand Up @@ -67,7 +70,10 @@ require (
github.com/docker/go-metrics v0.0.0-20181218153428-b84716841b82 // indirect
github.com/docker/go-units v0.4.0 // indirect
github.com/docker/libtrust v0.0.0-20160708172513-aabc10ec26b7 // indirect
github.com/felixge/httpsnoop v1.0.4 // indirect
github.com/garyburd/redigo v0.0.0-20150301180006-535138d7bcd7 // indirect
github.com/go-logr/logr v1.3.0 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-sql-driver/mysql v1.5.0 // indirect
github.com/gofrs/uuid v0.0.0-20190320161447-2593f3d8aa45 // indirect
github.com/gogo/googleapis v1.4.1 // indirect
Expand Down Expand Up @@ -100,6 +106,7 @@ require (
github.com/yvasiyarov/gorelic v0.0.0-20180809112600-635ca6035f23 // indirect
github.com/yvasiyarov/newrelic_platform_go v0.0.0-20160601141957-9c099fbc30e9 // indirect
go.opencensus.io v0.22.3 // indirect
go.opentelemetry.io/otel/metric v1.21.0 // indirect
go.uber.org/multierr v1.4.0 // indirect
go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee // indirect
golang.org/x/crypto v0.40.0 // indirect
Expand Down
21 changes: 17 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,8 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.m
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/erikstmartin/go-testdb v0.0.0-20160219214506-8d10e4a1bae5 h1:Yzb9+7DPaBjB8zlTR87/ElzFsnQfuHnVUVqpZZIcV5Y=
github.com/erikstmartin/go-testdb v0.0.0-20160219214506-8d10e4a1bae5/go.mod h1:a2zkGnVExMxdzMo3M0Hi/3sEU+cWnZpSni0O6/Yb/P0=
github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg=
github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
github.com/garyburd/redigo v0.0.0-20150301180006-535138d7bcd7 h1:LofdAjjjqCSXMwLGgOgnE+rdPuvX9DxCqaHwKy7i/ko=
Expand All @@ -190,6 +192,11 @@ github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY=
github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY=
github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag=
github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE=
github.com/go-openapi/jsonpointer v0.0.0-20160704185906-46af16f9f7b1/go.mod h1:+35s3my2LFTysnkMfxsJBAMHj/DoqoB9knIWoYG/Vk0=
github.com/go-openapi/jsonpointer v0.19.2/go.mod h1:3akKfEdA7DF1sugOqz1dVQHBcuDBPKZGEoHC/NkiQRg=
github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg=
Expand Down Expand Up @@ -454,16 +461,14 @@ github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/y
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.4 h1:wZRexSlwd7ZXfKINDLsO4r7WBt3gTKONc6K/VesHvHM=
github.com/stretchr/testify v1.7.4/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635 h1:kdXcSzyDtseVEc4yCz2qF8ZrQvIDBJLl4S1c3GCXmoI=
github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
Expand Down Expand Up @@ -499,6 +504,14 @@ go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.3 h1:8sGtKOrtQqkN1bp2AtX+misvLIlOmsEsNd+9NIcPEm8=
go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.0 h1:1eHu3/pUSWaOgltNK3WJFaywKsTIr/PwvHyDmi0lQA0=
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.0/go.mod h1:HyABWq60Uy1kjJSa2BVOxUVao8Cdick5AWSKPutqy6U=
go.opentelemetry.io/otel v1.21.0 h1:hzLeKBZEL7Okw2mGzZ0cc4k/A7Fta0uoPgaJCr8fsFc=
go.opentelemetry.io/otel v1.21.0/go.mod h1:QZzNPQPm1zLX4gZK4cMi+71eaorMSGT3A4znnUvNNEo=
go.opentelemetry.io/otel/metric v1.21.0 h1:tlYWfeo+Bocx5kLEloTjbcDwBuELRrIFxwdQ36PlJu4=
go.opentelemetry.io/otel/metric v1.21.0/go.mod h1:o1p3CA8nNHW8j5yuQLdc1eeqEaPfzug24uvsyIEJRWM=
go.opentelemetry.io/otel/trace v1.21.0 h1:WD9i5gzvoUPuXIXH24ZNBudiarZDKuekPqi/E8fpfLc=
go.opentelemetry.io/otel/trace v1.21.0/go.mod h1:LGbsEB0f9LGjN+OZaQQ26sohbOmiMR+BaslueVtS/qQ=
go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI=
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.5.0 h1:OI5t8sDa1Or+q8AeE+yKeB/SDYioSHAgcVljj9JIETY=
Expand Down
4 changes: 4 additions & 0 deletions nginx/config/build-index.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ server {
access_log {{.access_log_path}};
error_log {{.error_log_path}};

proxy_set_header traceparent $http_traceparent;
proxy_set_header tracestate $http_tracestate;
proxy_set_header jaeger-debug-id $http_jaeger_debug_id;

{{healthEndpoint "build-index"}}

location / {
Expand Down
Loading
Loading