elastic-apm 4.5.1 → 4.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ci/.jenkins_exclude.yml +73 -16
- data/.ci/.jenkins_framework.yml +3 -2
- data/.ci/.jenkins_ruby.yml +1 -1
- data/.ci/.jenkins_ruby_benchmarks.yml +6 -0
- data/.ci/Jenkinsfile +35 -26
- data/.ci/docker/jruby/11-jdk/Dockerfile +3 -0
- data/.ci/docker/jruby/12-jdk/Dockerfile +3 -0
- data/.ci/docker/jruby/13-jdk/Dockerfile +3 -0
- data/.ci/docker/jruby/7-jdk/Dockerfile +3 -0
- data/.ci/docker/jruby/8-jdk/Dockerfile +3 -0
- data/.ci/snapshoty.yml +34 -0
- data/.ci/update-specs.yml +108 -0
- data/.github/workflows/update-specs.yml +30 -0
- data/CHANGELOG.asciidoc +34 -0
- data/Gemfile +10 -3
- data/bench/report.rb +1 -1
- data/docker-compose.yml +6 -0
- data/docs/configuration.asciidoc +6 -4
- data/elastic-apm.gemspec +3 -2
- data/lib/elastic_apm/central_config.rb +5 -0
- data/lib/elastic_apm/config/server_info.rb +50 -0
- data/lib/elastic_apm/config.rb +25 -4
- data/lib/elastic_apm/error.rb +2 -1
- data/lib/elastic_apm/error_builder.rb +1 -0
- data/lib/elastic_apm/instrumenter.rb +4 -2
- data/lib/elastic_apm/metadata/system_info/container_info.rb +4 -3
- data/lib/elastic_apm/metadata/system_info.rb +1 -1
- data/lib/elastic_apm/span/context/links.rb +32 -0
- data/lib/elastic_apm/span/context/service.rb +55 -0
- data/lib/elastic_apm/span/context.rb +19 -3
- data/lib/elastic_apm/span.rb +3 -0
- data/lib/elastic_apm/span_helpers.rb +2 -2
- data/lib/elastic_apm/spies/faraday.rb +23 -0
- data/lib/elastic_apm/spies/racecar.rb +77 -0
- data/lib/elastic_apm/spies/redis.rb +1 -1
- data/lib/elastic_apm/spies/sequel.rb +9 -0
- data/lib/elastic_apm/spies/sqs.rb +1 -0
- data/lib/elastic_apm/trace_context/tracestate.rb +4 -2
- data/lib/elastic_apm/trace_context.rb +1 -1
- data/lib/elastic_apm/transport/connection/http.rb +9 -3
- data/lib/elastic_apm/transport/serializers/span_serializer.rb +25 -0
- data/lib/elastic_apm/version.rb +1 -1
- data/lib/elastic_apm.rb +1 -0
- metadata +26 -3
@@ -69,6 +69,14 @@ module ElasticAPM
|
|
69
69
|
base[:message] = build_message(context.message)
|
70
70
|
end
|
71
71
|
|
72
|
+
if context.service
|
73
|
+
base[:service] = build_service(context.service)
|
74
|
+
end
|
75
|
+
|
76
|
+
if context.links && !context.links.empty?
|
77
|
+
base[:links] = build_links(context.links)
|
78
|
+
end
|
79
|
+
|
72
80
|
base
|
73
81
|
end
|
74
82
|
|
@@ -121,6 +129,23 @@ module ElasticAPM
|
|
121
129
|
}
|
122
130
|
}
|
123
131
|
end
|
132
|
+
|
133
|
+
def build_service(service)
|
134
|
+
{
|
135
|
+
target: {
|
136
|
+
name: keyword_field(service.target&.name),
|
137
|
+
type: keyword_field(service.target&.type)
|
138
|
+
}
|
139
|
+
}
|
140
|
+
end
|
141
|
+
|
142
|
+
def build_links(links)
|
143
|
+
{
|
144
|
+
links: links.map do |link|
|
145
|
+
{"trace_id" => link.trace_id, "span_id" => link.span_id}
|
146
|
+
end
|
147
|
+
}
|
148
|
+
end
|
124
149
|
end
|
125
150
|
|
126
151
|
private
|
data/lib/elastic_apm/version.rb
CHANGED
data/lib/elastic_apm.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: elastic-apm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.
|
4
|
+
version: 4.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mikkel Malmberg
|
8
|
+
- Emily Stolfo
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date:
|
12
|
+
date: 2023-03-01 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: concurrent-ruby
|
@@ -38,9 +39,23 @@ dependencies:
|
|
38
39
|
- - ">="
|
39
40
|
- !ruby/object:Gem::Version
|
40
41
|
version: '3.0'
|
42
|
+
- !ruby/object:Gem::Dependency
|
43
|
+
name: ruby2_keywords
|
44
|
+
requirement: !ruby/object:Gem::Requirement
|
45
|
+
requirements:
|
46
|
+
- - ">="
|
47
|
+
- !ruby/object:Gem::Version
|
48
|
+
version: '0'
|
49
|
+
type: :runtime
|
50
|
+
prerelease: false
|
51
|
+
version_requirements: !ruby/object:Gem::Requirement
|
52
|
+
requirements:
|
53
|
+
- - ">="
|
54
|
+
- !ruby/object:Gem::Version
|
55
|
+
version: '0'
|
41
56
|
description:
|
42
57
|
email:
|
43
|
-
-
|
58
|
+
- info@elastic.co
|
44
59
|
executables: []
|
45
60
|
extensions: []
|
46
61
|
extra_rdoc_files: []
|
@@ -50,6 +65,7 @@ files:
|
|
50
65
|
- ".ci/.jenkins_framework.yml"
|
51
66
|
- ".ci/.jenkins_main_framework.yml"
|
52
67
|
- ".ci/.jenkins_ruby.yml"
|
68
|
+
- ".ci/.jenkins_ruby_benchmarks.yml"
|
53
69
|
- ".ci/Jenkinsfile"
|
54
70
|
- ".ci/docker/jruby/11-jdk/Dockerfile"
|
55
71
|
- ".ci/docker/jruby/12-jdk/Dockerfile"
|
@@ -66,6 +82,8 @@ files:
|
|
66
82
|
- ".ci/jobs/defaults.yml"
|
67
83
|
- ".ci/linting.groovy"
|
68
84
|
- ".ci/packer_cache.sh"
|
85
|
+
- ".ci/snapshoty.yml"
|
86
|
+
- ".ci/update-specs.yml"
|
69
87
|
- ".github/ISSUE_TEMPLATE/Bug_report.md"
|
70
88
|
- ".github/ISSUE_TEMPLATE/Feature_request.md"
|
71
89
|
- ".github/PULL_REQUEST_TEMPLATE.md"
|
@@ -73,6 +91,7 @@ files:
|
|
73
91
|
- ".github/labeler-config.yml"
|
74
92
|
- ".github/workflows/addToProject.yml"
|
75
93
|
- ".github/workflows/labeler.yml"
|
94
|
+
- ".github/workflows/update-specs.yml"
|
76
95
|
- ".gitignore"
|
77
96
|
- ".pre-commit-config.yaml"
|
78
97
|
- ".rspec"
|
@@ -136,6 +155,7 @@ files:
|
|
136
155
|
- lib/elastic_apm/config/options.rb
|
137
156
|
- lib/elastic_apm/config/regexp_list.rb
|
138
157
|
- lib/elastic_apm/config/round_float.rb
|
158
|
+
- lib/elastic_apm/config/server_info.rb
|
139
159
|
- lib/elastic_apm/config/wildcard_pattern_list.rb
|
140
160
|
- lib/elastic_apm/context.rb
|
141
161
|
- lib/elastic_apm/context/request.rb
|
@@ -192,7 +212,9 @@ files:
|
|
192
212
|
- lib/elastic_apm/span/context/db.rb
|
193
213
|
- lib/elastic_apm/span/context/destination.rb
|
194
214
|
- lib/elastic_apm/span/context/http.rb
|
215
|
+
- lib/elastic_apm/span/context/links.rb
|
195
216
|
- lib/elastic_apm/span/context/message.rb
|
217
|
+
- lib/elastic_apm/span/context/service.rb
|
196
218
|
- lib/elastic_apm/span_helpers.rb
|
197
219
|
- lib/elastic_apm/spies.rb
|
198
220
|
- lib/elastic_apm/spies/action_dispatch.rb
|
@@ -205,6 +227,7 @@ files:
|
|
205
227
|
- lib/elastic_apm/spies/json.rb
|
206
228
|
- lib/elastic_apm/spies/mongo.rb
|
207
229
|
- lib/elastic_apm/spies/net_http.rb
|
230
|
+
- lib/elastic_apm/spies/racecar.rb
|
208
231
|
- lib/elastic_apm/spies/rake.rb
|
209
232
|
- lib/elastic_apm/spies/redis.rb
|
210
233
|
- lib/elastic_apm/spies/resque.rb
|