summaryrefslogtreecommitdiff
path: root/vendor/github.com/uber/jaeger-client-go/sampler.go
diff options
context:
space:
mode:
authordependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>2019-09-30 12:40:36 +0000
committerValentin Rothberg <rothberg@redhat.com>2019-09-30 15:04:52 +0200
commit2f397ecdeb1f5f064e30c3ab9bf85f5c10c41afa (patch)
treea31c7db2b6c0d06975854212dac61de13f39807f /vendor/github.com/uber/jaeger-client-go/sampler.go
parent01b7af8ee9b3df1439c4da109ba11e7410108dab (diff)
downloadpodman-2f397ecdeb1f5f064e30c3ab9bf85f5c10c41afa.tar.gz
podman-2f397ecdeb1f5f064e30c3ab9bf85f5c10c41afa.tar.bz2
podman-2f397ecdeb1f5f064e30c3ab9bf85f5c10c41afa.zip
Bump github.com/uber/jaeger-client-go
Bumps [github.com/uber/jaeger-client-go](https://github.com/uber/jaeger-client-go) from 2.16.0+incompatible to 2.19.0+incompatible. - [Release notes](https://github.com/uber/jaeger-client-go/releases) - [Changelog](https://github.com/jaegertracing/jaeger-client-go/blob/master/CHANGELOG.md) - [Commits](https://github.com/uber/jaeger-client-go/compare/v2.16.0...v2.19.0) Signed-off-by: dependabot-preview[bot] <support@dependabot.com> Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Diffstat (limited to 'vendor/github.com/uber/jaeger-client-go/sampler.go')
-rw-r--r--vendor/github.com/uber/jaeger-client-go/sampler.go8
1 files changed, 5 insertions, 3 deletions
diff --git a/vendor/github.com/uber/jaeger-client-go/sampler.go b/vendor/github.com/uber/jaeger-client-go/sampler.go
index 3e1630953..ea6984e02 100644
--- a/vendor/github.com/uber/jaeger-client-go/sampler.go
+++ b/vendor/github.com/uber/jaeger-client-go/sampler.go
@@ -28,7 +28,6 @@ import (
)
const (
- defaultSamplingServerURL = "http://localhost:5778/sampling"
defaultSamplingRefreshInterval = time.Minute
defaultMaxOperations = 2000
)
@@ -348,24 +347,27 @@ func (s *adaptiveSampler) Equal(other Sampler) bool {
func (s *adaptiveSampler) update(strategies *sampling.PerOperationSamplingStrategies) {
s.Lock()
defer s.Unlock()
+ newSamplers := map[string]*GuaranteedThroughputProbabilisticSampler{}
for _, strategy := range strategies.PerOperationStrategies {
operation := strategy.Operation
samplingRate := strategy.ProbabilisticSampling.SamplingRate
lowerBound := strategies.DefaultLowerBoundTracesPerSecond
if sampler, ok := s.samplers[operation]; ok {
sampler.update(lowerBound, samplingRate)
+ newSamplers[operation] = sampler
} else {
sampler := newGuaranteedThroughputProbabilisticSampler(
lowerBound,
samplingRate,
)
- s.samplers[operation] = sampler
+ newSamplers[operation] = sampler
}
}
s.lowerBound = strategies.DefaultLowerBoundTracesPerSecond
if s.defaultSampler.SamplingRate() != strategies.DefaultSamplingProbability {
s.defaultSampler = newProbabilisticSampler(strategies.DefaultSamplingProbability)
}
+ s.samplers = newSamplers
}
// -----------------------
@@ -432,7 +434,7 @@ func applySamplerOptions(opts ...SamplerOption) samplerOptions {
options.maxOperations = defaultMaxOperations
}
if options.samplingServerURL == "" {
- options.samplingServerURL = defaultSamplingServerURL
+ options.samplingServerURL = DefaultSamplingServerURL
}
if options.metrics == nil {
options.metrics = NewNullMetrics()