elastic-transport 8.5.2 → 8.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ec964e43347f5b7ae8ab38e9f2403aa0f6bcd352c9169a2bcd4d54a1fa995957
4
- data.tar.gz: cdbd0d5ce004ec76ba29af96ae02a0e084a926dd6bf3808d507b8a7f80764b5e
3
+ metadata.gz: d1367aa286a53be8c0c3f93320afebd83849057b5aef6bead07660876cfbffc2
4
+ data.tar.gz: 2c795f10b5863477f782690af3791a50abdb8d05eeb4e40c5ba901a49f2ecf38
5
5
  SHA512:
6
- metadata.gz: 2809af5a1b46710a9b812aa11496266a83920e6efac87f1a30ed3e621963107b6bcc5d8362b297a07c9de4f3b030ecb0da34771ea27939513a5dc00b038503bd
7
- data.tar.gz: 8b43dc2f6a63901eb5566b1eeb8a0a9a8ac4e189981cdab1afc9a24e4e6a3e8f7a7a325d137d6e218390c79c8532d0092a803e751fa078f170fe6506c5f31c77
6
+ metadata.gz: 62b1b3175922a1999e8bace0eb9acbf7d3de89e3e12acc34d93f7bbe89353fae797fb39fa345d363d12d5ca1557ddbefdf7252aa3dd5e356bffffd764439e374
7
+ data.tar.gz: a34e264fd4f799322b737bcaa8647676367e823377c90cc3fa4b3979298bdb62ce2969c17d5aca4dfa6d95988b27ff209c77079f60001c03d449d983b2d1f403
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## 8.5.3
2
+
3
+ - Locks oj development dependency to >= 3.17.3 due to CVE
4
+ - Checks if @otel is defined
5
+ - Removes outdated Oj code
6
+
1
7
  ## 8.5.2
2
8
 
3
9
  - Minor refactor to `curb` implementation.
@@ -169,7 +169,7 @@ module Elastic
169
169
  def perform_request(method, path, params = {}, body = nil, headers = nil, opts = {})
170
170
  method = @send_get_body_as if method == 'GET' && body
171
171
  validate_ca_fingerprints if @ca_fingerprint
172
- if @otel
172
+ if defined?(@otel) && !@otel.nil?
173
173
  # If no endpoint is specified in the opts, use the HTTP method name
174
174
  span_name = opts[:endpoint] || method
175
175
  @otel.tracer.in_span(span_name) do |span|
@@ -356,15 +356,10 @@ module Elastic
356
356
  end
357
357
 
358
358
  if response.body &&
359
- !response.body.empty? &&
360
- response.headers &&
361
- response.headers["content-type"] =~ /json/
362
-
363
- # Prevent Float value from automatically becoming BigDecimal when using Oj
364
- load_options = {}
365
- load_options[:mode] = :compat if ::MultiJson.adapter.to_s == "MultiJson::Adapters::Oj"
366
-
367
- json = serializer.load(response.body, load_options)
359
+ !response.body.empty? &&
360
+ response.headers &&
361
+ response.headers['content-type'] =~ /json/
362
+ json = serializer.load(response.body)
368
363
  end
369
364
  took = (json['took'] ? sprintf('%.3fs', json['took'] / 1000.0) : 'n/a') rescue 'n/a'
370
365
  __log_response(method, path, params, body, url, response, json, took, duration) unless ignore.include?(response.status.to_i)
@@ -17,6 +17,6 @@
17
17
 
18
18
  module Elastic
19
19
  module Transport
20
- VERSION = '8.5.2'.freeze
20
+ VERSION = '8.5.3'.freeze
21
21
  end
22
22
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: elastic-transport
3
3
  version: !ruby/object:Gem::Version
4
- version: 8.5.2
4
+ version: 8.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic Client Library Maintainers