boost-jaeger-client 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +12 -0
- data/.rspec +2 -0
- data/.rubocop.yml +47 -0
- data/.travis.yml +5 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +57 -0
- data/Rakefile +9 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/boost-jaeger-client.gemspec +31 -0
- data/lib/jaeger/client/carrier.rb +26 -0
- data/lib/jaeger/client/collector.rb +91 -0
- data/lib/jaeger/client/samplers/const.rb +29 -0
- data/lib/jaeger/client/samplers/probabilistic.rb +30 -0
- data/lib/jaeger/client/samplers.rb +4 -0
- data/lib/jaeger/client/scope.rb +40 -0
- data/lib/jaeger/client/scope_manager/scope_identifier.rb +15 -0
- data/lib/jaeger/client/scope_manager/scope_stack.rb +35 -0
- data/lib/jaeger/client/scope_manager.rb +49 -0
- data/lib/jaeger/client/span/thrift_log_builder.rb +20 -0
- data/lib/jaeger/client/span/thrift_tag_builder.rb +45 -0
- data/lib/jaeger/client/span.rb +83 -0
- data/lib/jaeger/client/span_context.rb +78 -0
- data/lib/jaeger/client/trace_id.rb +13 -0
- data/lib/jaeger/client/tracer.rb +220 -0
- data/lib/jaeger/client/udp_sender/transport.rb +42 -0
- data/lib/jaeger/client/udp_sender.rb +82 -0
- data/lib/jaeger/client/version.rb +7 -0
- data/lib/jaeger/client.rb +44 -0
- data/script/create_follows_from_trace +52 -0
- data/script/create_trace +53 -0
- data/thrift/agent.thrift +32 -0
- data/thrift/gen-rb/jaeger/thrift/agent/agent.rb +118 -0
- data/thrift/gen-rb/jaeger/thrift/agent/agent_constants.rb +15 -0
- data/thrift/gen-rb/jaeger/thrift/agent/agent_types.rb +17 -0
- data/thrift/gen-rb/jaeger/thrift/agent.rb +116 -0
- data/thrift/gen-rb/jaeger/thrift/agent_constants.rb +13 -0
- data/thrift/gen-rb/jaeger/thrift/agent_types.rb +15 -0
- data/thrift/gen-rb/jaeger/thrift/collector.rb +82 -0
- data/thrift/gen-rb/jaeger/thrift/jaeger_constants.rb +13 -0
- data/thrift/gen-rb/jaeger/thrift/jaeger_types.rb +211 -0
- data/thrift/gen-rb/jaeger/thrift/zipkin/zipkin_collector.rb +84 -0
- data/thrift/gen-rb/jaeger/thrift/zipkin/zipkincore_constants.rb +41 -0
- data/thrift/gen-rb/jaeger/thrift/zipkin/zipkincore_types.rb +220 -0
- data/thrift/jaeger.thrift +88 -0
- data/thrift/zipkincore.thrift +300 -0
- metadata +190 -0
data/thrift/agent.thrift
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
# The MIT License (MIT)
|
2
|
+
#
|
3
|
+
# Copyright (c) 2016 Uber Technologies, Inc.
|
4
|
+
#
|
5
|
+
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
# of this software and associated documentation files (the "Software"), to deal
|
7
|
+
# in the Software without restriction, including without limitation the rights
|
8
|
+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
# copies of the Software, and to permit persons to whom the Software is
|
10
|
+
# furnished to do so, subject to the following conditions:
|
11
|
+
#
|
12
|
+
# The above copyright notice and this permission notice shall be included in
|
13
|
+
# all copies or substantial portions of the Software.
|
14
|
+
#
|
15
|
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
# THE SOFTWARE.
|
22
|
+
|
23
|
+
include "jaeger.thrift"
|
24
|
+
include "zipkincore.thrift"
|
25
|
+
|
26
|
+
namespace java com.uber.jaeger.agent.thrift
|
27
|
+
namespace rb Jaeger.Thrift
|
28
|
+
|
29
|
+
service Agent {
|
30
|
+
oneway void emitZipkinBatch(1: list<zipkincore.Span> spans)
|
31
|
+
oneway void emitBatch(1: jaeger.Batch batch)
|
32
|
+
}
|
@@ -0,0 +1,118 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
require 'jaeger/thrift/agent/agent_types'
|
9
|
+
|
10
|
+
module Jaeger
|
11
|
+
module Thrift
|
12
|
+
module Agent
|
13
|
+
module Agent
|
14
|
+
class Client
|
15
|
+
include ::Thrift::Client
|
16
|
+
|
17
|
+
def emitZipkinBatch(spans)
|
18
|
+
send_emitZipkinBatch(spans)
|
19
|
+
end
|
20
|
+
|
21
|
+
def send_emitZipkinBatch(spans)
|
22
|
+
send_oneway_message('emitZipkinBatch', EmitZipkinBatch_args, :spans => spans)
|
23
|
+
end
|
24
|
+
def emitBatch(batch)
|
25
|
+
send_emitBatch(batch)
|
26
|
+
end
|
27
|
+
|
28
|
+
def send_emitBatch(batch)
|
29
|
+
send_oneway_message('emitBatch', EmitBatch_args, :batch => batch)
|
30
|
+
end
|
31
|
+
end
|
32
|
+
|
33
|
+
class Processor
|
34
|
+
include ::Thrift::Processor
|
35
|
+
|
36
|
+
def process_emitZipkinBatch(seqid, iprot, oprot)
|
37
|
+
args = read_args(iprot, EmitZipkinBatch_args)
|
38
|
+
@handler.emitZipkinBatch(args.spans)
|
39
|
+
return
|
40
|
+
end
|
41
|
+
|
42
|
+
def process_emitBatch(seqid, iprot, oprot)
|
43
|
+
args = read_args(iprot, EmitBatch_args)
|
44
|
+
@handler.emitBatch(args.batch)
|
45
|
+
return
|
46
|
+
end
|
47
|
+
|
48
|
+
end
|
49
|
+
|
50
|
+
# HELPER FUNCTIONS AND STRUCTURES
|
51
|
+
|
52
|
+
class EmitZipkinBatch_args
|
53
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
54
|
+
SPANS = 1
|
55
|
+
|
56
|
+
FIELDS = {
|
57
|
+
SPANS => {:type => ::Thrift::Types::LIST, :name => 'spans', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Zipkin::Span}}
|
58
|
+
}
|
59
|
+
|
60
|
+
def struct_fields; FIELDS; end
|
61
|
+
|
62
|
+
def validate
|
63
|
+
end
|
64
|
+
|
65
|
+
::Thrift::Struct.generate_accessors self
|
66
|
+
end
|
67
|
+
|
68
|
+
class EmitZipkinBatch_result
|
69
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
70
|
+
|
71
|
+
FIELDS = {
|
72
|
+
|
73
|
+
}
|
74
|
+
|
75
|
+
def struct_fields; FIELDS; end
|
76
|
+
|
77
|
+
def validate
|
78
|
+
end
|
79
|
+
|
80
|
+
::Thrift::Struct.generate_accessors self
|
81
|
+
end
|
82
|
+
|
83
|
+
class EmitBatch_args
|
84
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
85
|
+
BATCH = 1
|
86
|
+
|
87
|
+
FIELDS = {
|
88
|
+
BATCH => {:type => ::Thrift::Types::STRUCT, :name => 'batch', :class => ::Jaeger::Thrift::Batch}
|
89
|
+
}
|
90
|
+
|
91
|
+
def struct_fields; FIELDS; end
|
92
|
+
|
93
|
+
def validate
|
94
|
+
end
|
95
|
+
|
96
|
+
::Thrift::Struct.generate_accessors self
|
97
|
+
end
|
98
|
+
|
99
|
+
class EmitBatch_result
|
100
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
101
|
+
|
102
|
+
FIELDS = {
|
103
|
+
|
104
|
+
}
|
105
|
+
|
106
|
+
def struct_fields; FIELDS; end
|
107
|
+
|
108
|
+
def validate
|
109
|
+
end
|
110
|
+
|
111
|
+
::Thrift::Struct.generate_accessors self
|
112
|
+
end
|
113
|
+
|
114
|
+
end
|
115
|
+
|
116
|
+
end
|
117
|
+
end
|
118
|
+
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
require 'jaeger/thrift/agent/agent_types'
|
9
|
+
|
10
|
+
module Jaeger
|
11
|
+
module Thrift
|
12
|
+
module Agent
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
require 'jaeger/thrift/jaeger_types'
|
9
|
+
require 'jaeger/thrift/zipkin/zipkincore_types'
|
10
|
+
|
11
|
+
|
12
|
+
module Jaeger
|
13
|
+
module Thrift
|
14
|
+
module Agent
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
@@ -0,0 +1,116 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
require 'jaeger/thrift/agent_types'
|
9
|
+
|
10
|
+
module Jaeger
|
11
|
+
module Thrift
|
12
|
+
module Agent
|
13
|
+
class Client
|
14
|
+
include ::Thrift::Client
|
15
|
+
|
16
|
+
def emitZipkinBatch(spans)
|
17
|
+
send_emitZipkinBatch(spans)
|
18
|
+
end
|
19
|
+
|
20
|
+
def send_emitZipkinBatch(spans)
|
21
|
+
send_oneway_message('emitZipkinBatch', EmitZipkinBatch_args, :spans => spans)
|
22
|
+
end
|
23
|
+
def emitBatch(batch)
|
24
|
+
send_emitBatch(batch)
|
25
|
+
end
|
26
|
+
|
27
|
+
def send_emitBatch(batch)
|
28
|
+
send_oneway_message('emitBatch', EmitBatch_args, :batch => batch)
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
class Processor
|
33
|
+
include ::Thrift::Processor
|
34
|
+
|
35
|
+
def process_emitZipkinBatch(seqid, iprot, oprot)
|
36
|
+
args = read_args(iprot, EmitZipkinBatch_args)
|
37
|
+
@handler.emitZipkinBatch(args.spans)
|
38
|
+
return
|
39
|
+
end
|
40
|
+
|
41
|
+
def process_emitBatch(seqid, iprot, oprot)
|
42
|
+
args = read_args(iprot, EmitBatch_args)
|
43
|
+
@handler.emitBatch(args.batch)
|
44
|
+
return
|
45
|
+
end
|
46
|
+
|
47
|
+
end
|
48
|
+
|
49
|
+
# HELPER FUNCTIONS AND STRUCTURES
|
50
|
+
|
51
|
+
class EmitZipkinBatch_args
|
52
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
53
|
+
SPANS = 1
|
54
|
+
|
55
|
+
FIELDS = {
|
56
|
+
SPANS => {:type => ::Thrift::Types::LIST, :name => 'spans', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Zipkin::Span}}
|
57
|
+
}
|
58
|
+
|
59
|
+
def struct_fields; FIELDS; end
|
60
|
+
|
61
|
+
def validate
|
62
|
+
end
|
63
|
+
|
64
|
+
::Thrift::Struct.generate_accessors self
|
65
|
+
end
|
66
|
+
|
67
|
+
class EmitZipkinBatch_result
|
68
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
69
|
+
|
70
|
+
FIELDS = {
|
71
|
+
|
72
|
+
}
|
73
|
+
|
74
|
+
def struct_fields; FIELDS; end
|
75
|
+
|
76
|
+
def validate
|
77
|
+
end
|
78
|
+
|
79
|
+
::Thrift::Struct.generate_accessors self
|
80
|
+
end
|
81
|
+
|
82
|
+
class EmitBatch_args
|
83
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
84
|
+
BATCH = 1
|
85
|
+
|
86
|
+
FIELDS = {
|
87
|
+
BATCH => {:type => ::Thrift::Types::STRUCT, :name => 'batch', :class => ::Jaeger::Thrift::Batch}
|
88
|
+
}
|
89
|
+
|
90
|
+
def struct_fields; FIELDS; end
|
91
|
+
|
92
|
+
def validate
|
93
|
+
end
|
94
|
+
|
95
|
+
::Thrift::Struct.generate_accessors self
|
96
|
+
end
|
97
|
+
|
98
|
+
class EmitBatch_result
|
99
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
100
|
+
|
101
|
+
FIELDS = {
|
102
|
+
|
103
|
+
}
|
104
|
+
|
105
|
+
def struct_fields; FIELDS; end
|
106
|
+
|
107
|
+
def validate
|
108
|
+
end
|
109
|
+
|
110
|
+
::Thrift::Struct.generate_accessors self
|
111
|
+
end
|
112
|
+
|
113
|
+
end
|
114
|
+
|
115
|
+
end
|
116
|
+
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
require 'jaeger/thrift/jaeger_types'
|
9
|
+
require 'jaeger/thrift/zipkin/zipkincore_types'
|
10
|
+
|
11
|
+
|
12
|
+
module Jaeger
|
13
|
+
module Thrift
|
14
|
+
end
|
15
|
+
end
|
@@ -0,0 +1,82 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
require 'jaeger/thrift/jaeger_types'
|
9
|
+
|
10
|
+
module Jaeger
|
11
|
+
module Thrift
|
12
|
+
module Collector
|
13
|
+
class Client
|
14
|
+
include ::Thrift::Client
|
15
|
+
|
16
|
+
def submitBatches(batches)
|
17
|
+
send_submitBatches(batches)
|
18
|
+
return recv_submitBatches()
|
19
|
+
end
|
20
|
+
|
21
|
+
def send_submitBatches(batches)
|
22
|
+
send_message('submitBatches', SubmitBatches_args, :batches => batches)
|
23
|
+
end
|
24
|
+
|
25
|
+
def recv_submitBatches()
|
26
|
+
result = receive_message(SubmitBatches_result)
|
27
|
+
return result.success unless result.success.nil?
|
28
|
+
raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'submitBatches failed: unknown result')
|
29
|
+
end
|
30
|
+
|
31
|
+
end
|
32
|
+
|
33
|
+
class Processor
|
34
|
+
include ::Thrift::Processor
|
35
|
+
|
36
|
+
def process_submitBatches(seqid, iprot, oprot)
|
37
|
+
args = read_args(iprot, SubmitBatches_args)
|
38
|
+
result = SubmitBatches_result.new()
|
39
|
+
result.success = @handler.submitBatches(args.batches)
|
40
|
+
write_result(result, oprot, 'submitBatches', seqid)
|
41
|
+
end
|
42
|
+
|
43
|
+
end
|
44
|
+
|
45
|
+
# HELPER FUNCTIONS AND STRUCTURES
|
46
|
+
|
47
|
+
class SubmitBatches_args
|
48
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
49
|
+
BATCHES = 1
|
50
|
+
|
51
|
+
FIELDS = {
|
52
|
+
BATCHES => {:type => ::Thrift::Types::LIST, :name => 'batches', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Batch}}
|
53
|
+
}
|
54
|
+
|
55
|
+
def struct_fields; FIELDS; end
|
56
|
+
|
57
|
+
def validate
|
58
|
+
end
|
59
|
+
|
60
|
+
::Thrift::Struct.generate_accessors self
|
61
|
+
end
|
62
|
+
|
63
|
+
class SubmitBatches_result
|
64
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
65
|
+
SUCCESS = 0
|
66
|
+
|
67
|
+
FIELDS = {
|
68
|
+
SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::BatchSubmitResponse}}
|
69
|
+
}
|
70
|
+
|
71
|
+
def struct_fields; FIELDS; end
|
72
|
+
|
73
|
+
def validate
|
74
|
+
end
|
75
|
+
|
76
|
+
::Thrift::Struct.generate_accessors self
|
77
|
+
end
|
78
|
+
|
79
|
+
end
|
80
|
+
|
81
|
+
end
|
82
|
+
end
|
@@ -0,0 +1,211 @@
|
|
1
|
+
#
|
2
|
+
# Autogenerated by Thrift Compiler (0.10.0)
|
3
|
+
#
|
4
|
+
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
5
|
+
#
|
6
|
+
|
7
|
+
require 'thrift'
|
8
|
+
|
9
|
+
module Jaeger
|
10
|
+
module Thrift
|
11
|
+
module TagType
|
12
|
+
STRING = 0
|
13
|
+
DOUBLE = 1
|
14
|
+
BOOL = 2
|
15
|
+
LONG = 3
|
16
|
+
BINARY = 4
|
17
|
+
VALUE_MAP = {0 => "STRING", 1 => "DOUBLE", 2 => "BOOL", 3 => "LONG", 4 => "BINARY"}
|
18
|
+
VALID_VALUES = Set.new([STRING, DOUBLE, BOOL, LONG, BINARY]).freeze
|
19
|
+
end
|
20
|
+
|
21
|
+
module SpanRefType
|
22
|
+
CHILD_OF = 0
|
23
|
+
FOLLOWS_FROM = 1
|
24
|
+
VALUE_MAP = {0 => "CHILD_OF", 1 => "FOLLOWS_FROM"}
|
25
|
+
VALID_VALUES = Set.new([CHILD_OF, FOLLOWS_FROM]).freeze
|
26
|
+
end
|
27
|
+
|
28
|
+
class Tag
|
29
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
30
|
+
KEY = 1
|
31
|
+
VTYPE = 2
|
32
|
+
VSTR = 3
|
33
|
+
VDOUBLE = 4
|
34
|
+
VBOOL = 5
|
35
|
+
VLONG = 6
|
36
|
+
VBINARY = 7
|
37
|
+
|
38
|
+
FIELDS = {
|
39
|
+
KEY => {:type => ::Thrift::Types::STRING, :name => 'key'},
|
40
|
+
VTYPE => {:type => ::Thrift::Types::I32, :name => 'vType', :enum_class => ::Jaeger::Thrift::TagType},
|
41
|
+
VSTR => {:type => ::Thrift::Types::STRING, :name => 'vStr', :optional => true},
|
42
|
+
VDOUBLE => {:type => ::Thrift::Types::DOUBLE, :name => 'vDouble', :optional => true},
|
43
|
+
VBOOL => {:type => ::Thrift::Types::BOOL, :name => 'vBool', :optional => true},
|
44
|
+
VLONG => {:type => ::Thrift::Types::I64, :name => 'vLong', :optional => true},
|
45
|
+
VBINARY => {:type => ::Thrift::Types::STRING, :name => 'vBinary', :binary => true, :optional => true}
|
46
|
+
}
|
47
|
+
|
48
|
+
def struct_fields; FIELDS; end
|
49
|
+
|
50
|
+
def validate
|
51
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field key is unset!') unless @key
|
52
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field vType is unset!') unless @vType
|
53
|
+
unless @vType.nil? || ::Jaeger::Thrift::TagType::VALID_VALUES.include?(@vType)
|
54
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field vType!')
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
::Thrift::Struct.generate_accessors self
|
59
|
+
end
|
60
|
+
|
61
|
+
class Log
|
62
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
63
|
+
TIMESTAMP = 1
|
64
|
+
LOG_FIELDS = 2
|
65
|
+
|
66
|
+
FIELDS = {
|
67
|
+
TIMESTAMP => {:type => ::Thrift::Types::I64, :name => 'timestamp'},
|
68
|
+
LOG_FIELDS => {:type => ::Thrift::Types::LIST, :name => 'fields', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Tag}}
|
69
|
+
}
|
70
|
+
|
71
|
+
def struct_fields; FIELDS; end
|
72
|
+
|
73
|
+
def validate
|
74
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field timestamp is unset!') unless @timestamp
|
75
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field fields is unset!') unless @fields
|
76
|
+
end
|
77
|
+
|
78
|
+
::Thrift::Struct.generate_accessors self
|
79
|
+
end
|
80
|
+
|
81
|
+
class SpanRef
|
82
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
83
|
+
REFTYPE = 1
|
84
|
+
TRACEIDLOW = 2
|
85
|
+
TRACEIDHIGH = 3
|
86
|
+
SPANID = 4
|
87
|
+
|
88
|
+
FIELDS = {
|
89
|
+
REFTYPE => {:type => ::Thrift::Types::I32, :name => 'refType', :enum_class => ::Jaeger::Thrift::SpanRefType},
|
90
|
+
TRACEIDLOW => {:type => ::Thrift::Types::I64, :name => 'traceIdLow'},
|
91
|
+
TRACEIDHIGH => {:type => ::Thrift::Types::I64, :name => 'traceIdHigh'},
|
92
|
+
SPANID => {:type => ::Thrift::Types::I64, :name => 'spanId'}
|
93
|
+
}
|
94
|
+
|
95
|
+
def struct_fields; FIELDS; end
|
96
|
+
|
97
|
+
def validate
|
98
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field refType is unset!') unless @refType
|
99
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field traceIdLow is unset!') unless @traceIdLow
|
100
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field traceIdHigh is unset!') unless @traceIdHigh
|
101
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field spanId is unset!') unless @spanId
|
102
|
+
unless @refType.nil? || ::Jaeger::Thrift::SpanRefType::VALID_VALUES.include?(@refType)
|
103
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field refType!')
|
104
|
+
end
|
105
|
+
end
|
106
|
+
|
107
|
+
::Thrift::Struct.generate_accessors self
|
108
|
+
end
|
109
|
+
|
110
|
+
class Span
|
111
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
112
|
+
TRACEIDLOW = 1
|
113
|
+
TRACEIDHIGH = 2
|
114
|
+
SPANID = 3
|
115
|
+
PARENTSPANID = 4
|
116
|
+
OPERATIONNAME = 5
|
117
|
+
REFERENCES = 6
|
118
|
+
FLAGS = 7
|
119
|
+
STARTTIME = 8
|
120
|
+
DURATION = 9
|
121
|
+
TAGS = 10
|
122
|
+
LOGS = 11
|
123
|
+
|
124
|
+
FIELDS = {
|
125
|
+
TRACEIDLOW => {:type => ::Thrift::Types::I64, :name => 'traceIdLow'},
|
126
|
+
TRACEIDHIGH => {:type => ::Thrift::Types::I64, :name => 'traceIdHigh'},
|
127
|
+
SPANID => {:type => ::Thrift::Types::I64, :name => 'spanId'},
|
128
|
+
PARENTSPANID => {:type => ::Thrift::Types::I64, :name => 'parentSpanId'},
|
129
|
+
OPERATIONNAME => {:type => ::Thrift::Types::STRING, :name => 'operationName'},
|
130
|
+
REFERENCES => {:type => ::Thrift::Types::LIST, :name => 'references', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::SpanRef}, :optional => true},
|
131
|
+
FLAGS => {:type => ::Thrift::Types::I32, :name => 'flags'},
|
132
|
+
STARTTIME => {:type => ::Thrift::Types::I64, :name => 'startTime'},
|
133
|
+
DURATION => {:type => ::Thrift::Types::I64, :name => 'duration'},
|
134
|
+
TAGS => {:type => ::Thrift::Types::LIST, :name => 'tags', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Tag}, :optional => true},
|
135
|
+
LOGS => {:type => ::Thrift::Types::LIST, :name => 'logs', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Log}, :optional => true}
|
136
|
+
}
|
137
|
+
|
138
|
+
def struct_fields; FIELDS; end
|
139
|
+
|
140
|
+
def validate
|
141
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field traceIdLow is unset!') unless @traceIdLow
|
142
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field traceIdHigh is unset!') unless @traceIdHigh
|
143
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field spanId is unset!') unless @spanId
|
144
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field parentSpanId is unset!') unless @parentSpanId
|
145
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationName is unset!') unless @operationName
|
146
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field flags is unset!') unless @flags
|
147
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field startTime is unset!') unless @startTime
|
148
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field duration is unset!') unless @duration
|
149
|
+
end
|
150
|
+
|
151
|
+
::Thrift::Struct.generate_accessors self
|
152
|
+
end
|
153
|
+
|
154
|
+
class Process
|
155
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
156
|
+
SERVICENAME = 1
|
157
|
+
TAGS = 2
|
158
|
+
|
159
|
+
FIELDS = {
|
160
|
+
SERVICENAME => {:type => ::Thrift::Types::STRING, :name => 'serviceName'},
|
161
|
+
TAGS => {:type => ::Thrift::Types::LIST, :name => 'tags', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Tag}, :optional => true}
|
162
|
+
}
|
163
|
+
|
164
|
+
def struct_fields; FIELDS; end
|
165
|
+
|
166
|
+
def validate
|
167
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field serviceName is unset!') unless @serviceName
|
168
|
+
end
|
169
|
+
|
170
|
+
::Thrift::Struct.generate_accessors self
|
171
|
+
end
|
172
|
+
|
173
|
+
class Batch
|
174
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
175
|
+
PROCESS = 1
|
176
|
+
SPANS = 2
|
177
|
+
|
178
|
+
FIELDS = {
|
179
|
+
PROCESS => {:type => ::Thrift::Types::STRUCT, :name => 'process', :class => ::Jaeger::Thrift::Process},
|
180
|
+
SPANS => {:type => ::Thrift::Types::LIST, :name => 'spans', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Jaeger::Thrift::Span}}
|
181
|
+
}
|
182
|
+
|
183
|
+
def struct_fields; FIELDS; end
|
184
|
+
|
185
|
+
def validate
|
186
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field process is unset!') unless @process
|
187
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field spans is unset!') unless @spans
|
188
|
+
end
|
189
|
+
|
190
|
+
::Thrift::Struct.generate_accessors self
|
191
|
+
end
|
192
|
+
|
193
|
+
class BatchSubmitResponse
|
194
|
+
include ::Thrift::Struct, ::Thrift::Struct_Union
|
195
|
+
OK = 1
|
196
|
+
|
197
|
+
FIELDS = {
|
198
|
+
OK => {:type => ::Thrift::Types::BOOL, :name => 'ok'}
|
199
|
+
}
|
200
|
+
|
201
|
+
def struct_fields; FIELDS; end
|
202
|
+
|
203
|
+
def validate
|
204
|
+
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field ok is unset!') if @ok.nil?
|
205
|
+
end
|
206
|
+
|
207
|
+
::Thrift::Struct.generate_accessors self
|
208
|
+
end
|
209
|
+
|
210
|
+
end
|
211
|
+
end
|