-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdeprecated.go
66 lines (55 loc) · 2.89 KB
/
deprecated.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
package otelpyroscope
// Config describes tracer configuration.
// DEPRECATED: Do not use.
type Config struct {
AppName string
PyroscopeURL string
IncludeProfileURL bool
IncludeProfileBaselineURL bool
ProfileBaselineLabels map[string]string
RootOnly bool
AddSpanName bool
}
// WithRootSpanOnly indicates that only the root span is to be profiled.
// The profile includes samples captured during child span execution
// but the spans won't have their own profiles and won't be annotated
// with pyroscope.profile attributes.
// The option is enabled by default.
// DEPRECATED: Ignored by tracer.
func WithRootSpanOnly(bool) Option { return func(tp *tracerProvider) {} }
// WithAddSpanName specifies whether the current span name should be added
// to the profile labels. N.B if the name is dynamic, or too many values
// are supposed, this may significantly deteriorate performance.
// By default, span name is not added to profile labels.
// DEPRECATED: Ignored by tracer.
func WithAddSpanName(bool) Option { return func(tp *tracerProvider) {} }
// WithAppName specifies the profiled application name.
// It should match the name specified in pyroscope configuration.
// Required, if profile URL or profile baseline URL is enabled.
// DEPRECATED: Ignored by tracer.
func WithAppName(string) Option { return func(tp *tracerProvider) {} }
// WithPyroscopeURL provides a base URL for the profile and baseline URLs.
// Required, if profile URL or profile baseline URL is enabled.
// DEPRECATED: Ignored by tracer.
func WithPyroscopeURL(string) Option { return func(tp *tracerProvider) {} }
// WithProfileURL specifies whether to add the pyroscope.profile.url
// attribute with the URL to the span profile.
// DEPRECATED: Ignored by tracer.
func WithProfileURL(bool) Option { return func(tp *tracerProvider) {} }
// WithProfileBaselineURL specifies whether to add the
// pyroscope.profile.baseline.url attribute with the URL
// to the baseline profile. See WithProfileBaselineLabels.
// DEPRECATED: Ignored by tracer.
func WithProfileBaselineURL(bool) Option { return func(tp *tracerProvider) {} }
// WithProfileBaselineLabels provides a map of extra labels to be added to the
// baseline query alongside with pprof labels set in runtime. Typically,
// it should match the labels specified in the Pyroscope profiler config.
// Note that the map must not be modified.
// DEPRECATED: Ignored by tracer.
func WithProfileBaselineLabels(map[string]string) Option { return func(tp *tracerProvider) {} }
// WithProfileURLBuilder specifies how profile URL is to be built.
// DEPRECATED: Ignored by tracer.
func WithProfileURLBuilder(func(_ string) string) Option { return func(tp *tracerProvider) {} }
// WithDefaultProfileURLBuilder specifies the default profile URL builder.
// DEPRECATED: Ignored by tracer.
func WithDefaultProfileURLBuilder(_, _ string) Option { return func(tp *tracerProvider) {} }