-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathspan_config.h
37 lines (31 loc) · 1.01 KB
/
span_config.h
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
#pragma once
// This component provides a `struct`, `SpanConfig`, used to specify span
// properties when a span is created. The following member functions accept a
// `SpanConfig` argument:
//
// - `Tracer::create_span`
// - `Tracer::extract_span`
// - `Span::create_child`
//
// `SpanConfig` contains much of the same information as `SpanDefaults`, but the
// two types have different purposes. `SpanDefaults` are the properties used
// when no corresponding property is specified in a `SpanConfig` argument.
// See `SpanData::apply_config`.
#include <string>
#include <unordered_map>
#include "clock.h"
#include "optional.h"
namespace datadog {
namespace tracing {
struct SpanConfig {
Optional<std::string> service;
Optional<std::string> service_type;
Optional<std::string> version;
Optional<std::string> environment;
Optional<std::string> name;
Optional<std::string> resource;
Optional<TimePoint> start;
std::unordered_map<std::string, std::string> tags;
};
} // namespace tracing
} // namespace datadog