opentelemetry-instrumentation-mysql2 0.24.0 → 0.24.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e5556a962e40c18ff1e4c02618b9772bb6a9708bbcfa4867c62924118bfdf1de
4
- data.tar.gz: 856f5881c0c843902bf79b38969f9dc20e9286719ebccde33c4155a2f4b06e54
3
+ metadata.gz: dc61812fab4c92e4f0fef950be41dfc2135c48852790c64a6bfa3967673ab669
4
+ data.tar.gz: 6fcfa90cdf624d165976c691a1503181bd41fb6c7650f65762b1b09f60f7ac51
5
5
  SHA512:
6
- metadata.gz: 36a64234a88f39e07e957721e434633db8636c86467a457fe298492100c9c36f465b37aa36ee4f6a7b37d3747bb1df7c338077514b27e41f867697e19f1dda78
7
- data.tar.gz: 6c8f6ffa8a510838c2c559da473b57edd7024d21696bcc143a8bfad6eb6ccba86e021a11cb6b8e9a6deee56ee4dab711274685a3e6bd3792ac6b7fa7e861e44c
6
+ metadata.gz: 3938c65f9dc2a1f8b05693655fbd23e646bd4138fe7eb7af651dcf3d0364f4cf2763fa9ffae5410492e68af7de2f8c7d393a150e7bb26e8a9ddcbcf0bfffd951
7
+ data.tar.gz: 46b83d31d0f8fa0eb058f8375097b57c828269b58cd0d71231d1e98cb48873e00fad40489bafdd820205cdff721b307faa274469bdbe87361711b2d7eb652df4
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Release History: opentelemetry-instrumentation-mysql2
2
2
 
3
+ ### v0.24.2 / 2023-06-05
4
+
5
+ * FIXED: Base config options
6
+
7
+ ### v0.24.1 / 2023-06-01
8
+
9
+ * FIXED: Regex non-match with obfuscation limit (issue #486)
10
+
3
11
  ### v0.24.0 / 2023-05-25
4
12
 
5
13
  * ADDED: Add config[:obfuscation_limit] to pg and mysql2
@@ -72,8 +72,12 @@ module OpenTelemetry
72
72
 
73
73
  def obfuscate_sql(sql)
74
74
  if sql.size > config[:obfuscation_limit]
75
- truncated_sql = sql[..sql.index(generated_mysql_regex) - 1]
76
- truncated_sql + "...\nSQL truncated (> #{config[:obfuscation_limit]} characters)"
75
+ first_match_index = sql.index(generated_mysql_regex)
76
+ truncation_message = "SQL truncated (> #{config[:obfuscation_limit]} characters)"
77
+ return truncation_message unless first_match_index
78
+
79
+ truncated_sql = sql[..first_match_index - 1]
80
+ "#{truncated_sql}...\n#{truncation_message}"
77
81
  else
78
82
  obfuscated = OpenTelemetry::Common::Utilities.utf8_encode(sql, binary: true)
79
83
  obfuscated = obfuscated.gsub(generated_mysql_regex, '?')
@@ -7,7 +7,7 @@
7
7
  module OpenTelemetry
8
8
  module Instrumentation
9
9
  module Mysql2
10
- VERSION = '0.24.0'
10
+ VERSION = '0.24.2'
11
11
  end
12
12
  end
13
13
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opentelemetry-instrumentation-mysql2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.24.0
4
+ version: 0.24.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenTelemetry Authors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-25 00:00:00.000000000 Z
11
+ date: 2023-06-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: opentelemetry-api
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 0.22.0
33
+ version: 0.22.1
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 0.22.0
40
+ version: 0.22.1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: appraisal
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -227,10 +227,10 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby-contrib
227
227
  licenses:
228
228
  - Apache-2.0
229
229
  metadata:
230
- changelog_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-mysql2/0.24.0/file/CHANGELOG.md
230
+ changelog_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-mysql2/0.24.2/file/CHANGELOG.md
231
231
  source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/instrumentation/mysql2
232
232
  bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues
233
- documentation_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-mysql2/0.24.0
233
+ documentation_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-mysql2/0.24.2
234
234
  post_install_message:
235
235
  rdoc_options: []
236
236
  require_paths: