diff options
author | Anton Evangelatov <anton.evangelatov@gmail.com> | 2019-03-21 04:30:34 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-21 04:30:34 +0800 |
commit | baded64d8819ece2bb715bf707882017dca03ae4 (patch) | |
tree | f7a198688d2be68ce4fad5030363ae31b1500eef /vendor | |
parent | c53c5e616f04ae8b041bfb64309cbc7f3e70303a (diff) | |
download | go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.tar go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.tar.gz go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.tar.bz2 go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.tar.lz go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.tar.xz go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.tar.zst go-tangerine-baded64d8819ece2bb715bf707882017dca03ae4.zip |
swarm/network: measure time of messages in priority queue (#19250)
Diffstat (limited to 'vendor')
6 files changed, 24 insertions, 26 deletions
diff --git a/vendor/github.com/opentracing/opentracing-go/CHANGELOG.md b/vendor/github.com/opentracing/opentracing-go/CHANGELOG.md index 1fc9fdf7f..ecfb7e3b7 100644 --- a/vendor/github.com/opentracing/opentracing-go/CHANGELOG.md +++ b/vendor/github.com/opentracing/opentracing-go/CHANGELOG.md @@ -10,5 +10,5 @@ Changes by Version 1.0.0 (2016-09-26) ------------------- -- This release implements OpenTracing Specification 1.0 (http://opentracing.io/spec) +- This release implements OpenTracing Specification 1.0 (https://opentracing.io/spec) diff --git a/vendor/github.com/opentracing/opentracing-go/Makefile b/vendor/github.com/opentracing/opentracing-go/Makefile index d49a5c0d4..62abb63f5 100644 --- a/vendor/github.com/opentracing/opentracing-go/Makefile +++ b/vendor/github.com/opentracing/opentracing-go/Makefile @@ -1,26 +1,15 @@ -PACKAGES := . ./mocktracer/... ./ext/... - .DEFAULT_GOAL := test-and-lint -.PHONE: test-and-lint - +.PHONY: test-and-lint test-and-lint: test lint .PHONY: test test: go test -v -cover -race ./... +.PHONY: cover cover: - @rm -rf cover-all.out - $(foreach pkg, $(PACKAGES), $(MAKE) cover-pkg PKG=$(pkg) || true;) - @grep mode: cover.out > coverage.out - @cat cover-all.out >> coverage.out - go tool cover -html=coverage.out -o cover.html - @rm -rf cover.out cover-all.out coverage.out - -cover-pkg: - go test -coverprofile cover.out $(PKG) - @grep -v mode: cover.out >> cover-all.out + go test -v -coverprofile=coverage.txt -covermode=atomic -race ./... .PHONY: lint lint: @@ -29,4 +18,3 @@ lint: @# Run again with magic to exit non-zero if golint outputs anything. @! (golint ./... | read dummy) go vet ./... - diff --git a/vendor/github.com/opentracing/opentracing-go/README.md b/vendor/github.com/opentracing/opentracing-go/README.md index 007ee237c..6ef1d7c9d 100644 --- a/vendor/github.com/opentracing/opentracing-go/README.md +++ b/vendor/github.com/opentracing/opentracing-go/README.md @@ -8,8 +8,8 @@ This package is a Go platform API for OpenTracing. ## Required Reading In order to understand the Go platform API, one must first be familiar with the -[OpenTracing project](http://opentracing.io) and -[terminology](http://opentracing.io/documentation/pages/spec.html) more specifically. +[OpenTracing project](https://opentracing.io) and +[terminology](https://opentracing.io/specification/) more specifically. ## API overview for those adding instrumentation diff --git a/vendor/github.com/opentracing/opentracing-go/globaltracer.go b/vendor/github.com/opentracing/opentracing-go/globaltracer.go index 8c8e793ff..4f7066a92 100644 --- a/vendor/github.com/opentracing/opentracing-go/globaltracer.go +++ b/vendor/github.com/opentracing/opentracing-go/globaltracer.go @@ -1,7 +1,12 @@ package opentracing +type registeredTracer struct { + tracer Tracer + isRegistered bool +} + var ( - globalTracer Tracer = NoopTracer{} + globalTracer = registeredTracer{NoopTracer{}, false} ) // SetGlobalTracer sets the [singleton] opentracing.Tracer returned by @@ -11,22 +16,27 @@ var ( // Prior to calling `SetGlobalTracer`, any Spans started via the `StartSpan` // (etc) globals are noops. func SetGlobalTracer(tracer Tracer) { - globalTracer = tracer + globalTracer = registeredTracer{tracer, true} } // GlobalTracer returns the global singleton `Tracer` implementation. // Before `SetGlobalTracer()` is called, the `GlobalTracer()` is a noop // implementation that drops all data handed to it. func GlobalTracer() Tracer { - return globalTracer + return globalTracer.tracer } // StartSpan defers to `Tracer.StartSpan`. See `GlobalTracer()`. func StartSpan(operationName string, opts ...StartSpanOption) Span { - return globalTracer.StartSpan(operationName, opts...) + return globalTracer.tracer.StartSpan(operationName, opts...) } // InitGlobalTracer is deprecated. Please use SetGlobalTracer. func InitGlobalTracer(tracer Tracer) { SetGlobalTracer(tracer) } + +// IsGlobalTracerRegistered returns a `bool` to indicate if a tracer has been globally registered +func IsGlobalTracerRegistered() bool { + return globalTracer.isRegistered +} diff --git a/vendor/github.com/opentracing/opentracing-go/propagation.go b/vendor/github.com/opentracing/opentracing-go/propagation.go index 0dd466a37..b0c275eb0 100644 --- a/vendor/github.com/opentracing/opentracing-go/propagation.go +++ b/vendor/github.com/opentracing/opentracing-go/propagation.go @@ -160,7 +160,7 @@ type HTTPHeadersCarrier http.Header // Set conforms to the TextMapWriter interface. func (c HTTPHeadersCarrier) Set(key, val string) { h := http.Header(c) - h.Add(key, val) + h.Set(key, val) } // ForeachKey conforms to the TextMapReader interface. diff --git a/vendor/vendor.json b/vendor/vendor.json index c2c7d7c3d..e965b4d7f 100644 --- a/vendor/vendor.json +++ b/vendor/vendor.json @@ -352,10 +352,10 @@ "revisionTime": "2017-01-28T05:05:32Z" }, { - "checksumSHA1": "wIcN7tZiF441h08RHAm4NV8cYO4=", + "checksumSHA1": "a/DHmc9bdsYlZZcwp6i3xhvV7Pk=", "path": "github.com/opentracing/opentracing-go", - "revision": "bd9c3193394760d98b2fa6ebb2291f0cd1d06a7d", - "revisionTime": "2018-06-06T20:41:48Z" + "revision": "25a84ff92183e2f8ac018ba1db54f8a07b3c0e04", + "revisionTime": "2019-02-18T02:30:34Z" }, { "checksumSHA1": "uhDxBvLEqRAMZKgpTZ8MFuLIIM8=", |