File tree 1 file changed +17
-0
lines changed
1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change 32
32
// BDE
33
33
#include < bsl_memory.h>
34
34
#include < bsl_string_view.h>
35
+ #include < bsl_vector.h>
35
36
36
37
namespace BloombergLP {
37
38
namespace bmqpi {
@@ -56,6 +57,22 @@ class DTTracer {
56
57
const bsl::shared_ptr<DTSpan>& parent,
57
58
const bsl::string_view& operation,
58
59
const DTSpan::Baggage& baggage = DTSpan::Baggage()) const = 0;
60
+
61
+ // / Serialize the underlying context for a specified `DTSpan` and return
62
+ // / the bit stream as `out`. Return 0 on success, or a non-zero error code
63
+ // / on error.
64
+ virtual int serializeSpan (bsl::vector<unsigned char >* out,
65
+ const bsl::shared_ptr<DTSpan>& dtSpan) = 0;
66
+
67
+ // / Deserialize the specified bit stream `in` into a context for a span.
68
+ // / Create a child span and pass into `out` based on the deserialized span,
69
+ // / the given `operation`, and an optional key-value tags defined by
70
+ // / `baggage`. Return 0 on success, or a non-zero error code on error.
71
+ virtual int deserializeAndCreateChildSpan (
72
+ bsl::shared_ptr<DTSpan>* out,
73
+ const bsl::vector<unsigned char >& in,
74
+ const bsl::string_view& operation,
75
+ const DTSpan::Baggage& baggage = DTSpan::Baggage()) = 0;
59
76
};
60
77
61
78
} // close package namespace
You can’t perform that action at this time.
0 commit comments