inst_statsd 3.0.3 → 3.0.5

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: d30f765062a97af9d2fb24f537f909d280ff5c4e3f73e88f26a295672beceb70
4
- data.tar.gz: ec16ef1cf597f17562545f61919d554eea88cca7c7c41d490018ce554fa052ea
3
+ metadata.gz: a33a17cc0b4ff4ceba7edeb8b326e165a91a4accdf95d5b8452e5e015df793e5
4
+ data.tar.gz: e602f9889485fa588d14e8457f7cddcbe075be733f9075594a663c517ab3f07c
5
5
  SHA512:
6
- metadata.gz: 7abdd65611b4a20abdbbf84041365269fd78dec587cdaa82a34445ed79f48b884bca0fe36fba5771723b9130354e0eb6e77110686d5418997a2d86fd2036b7ad
7
- data.tar.gz: 861b9d44c819dcae0d776c0e180b5b26000023bc8ce2d73a32009ed7533fa6840e00faad63c56be6991004ccc84b3ff9735adbbaa2931e790a7155831e81409b
6
+ metadata.gz: b4488ce5d63fb8e490ff5be51fc18e2ab36b0af52d4e0788735ea2c580fd3b4d8d02db4a4bf377c1c43e6847c8a1d5bec6719d8073a38129b91f75871a4a6773
7
+ data.tar.gz: 171e4007599cef67ad980034ab702d6575891ccc286d7769df11ce264fd93a6e61df29d542fffd39d094171ea0e4703c2d9d73941dbef203f359bc4bfaba028c
@@ -57,7 +57,7 @@ module InstStatsd
57
57
 
58
58
  def tags_from_opts(tags, type, dd_tags)
59
59
  custom_tags = tags.merge(dd_tags)
60
- custom_tags[:type] = type if SUPPORTED_TYPES.include? type
60
+ custom_tags[:type] = type.to_sym if SUPPORTED_TYPES.include? type&.to_sym
61
61
  custom_tags.compact
62
62
  end
63
63
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module InstStatsd
4
- VERSION = "3.0.3"
4
+ VERSION = "3.0.5"
5
5
  end
data/lib/inst_statsd.rb CHANGED
@@ -11,7 +11,8 @@ module InstStatsd
11
11
  negative_mask
12
12
  batch_size
13
13
  batch_byte_size
14
- dog_tags].freeze
14
+ dog_tags
15
+ socket_path].freeze
15
16
 
16
17
  class ConfigurationError < StandardError; end
17
18
 
@@ -105,6 +105,20 @@ RSpec.describe InstStatsd::Event do
105
105
  end
106
106
  end
107
107
 
108
+ context "with a valid type set as a string" do
109
+ let(:opts) { { type: "deploy" } }
110
+
111
+ it "sets the valid aggregation key" do
112
+ expect(instance).to receive(:event).with(
113
+ title,
114
+ text,
115
+ tags: { type: :deploy }
116
+ )
117
+
118
+ subject
119
+ end
120
+ end
121
+
108
122
  context "with custom tags" do
109
123
  let(:opts) { { tags: { project: "cool-project" } } }
110
124
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: inst_statsd
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.3
4
+ version: 3.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Cloward
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2023-09-08 00:00:00.000000000 Z
12
+ date: 2024-09-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: aroi
@@ -65,20 +65,6 @@ dependencies:
65
65
  - - "~>"
66
66
  - !ruby/object:Gem::Version
67
67
  version: '1.0'
68
- - !ruby/object:Gem::Dependency
69
- name: appraisal
70
- requirement: !ruby/object:Gem::Requirement
71
- requirements:
72
- - - ">="
73
- - !ruby/object:Gem::Version
74
- version: '0'
75
- type: :development
76
- prerelease: false
77
- version_requirements: !ruby/object:Gem::Requirement
78
- requirements:
79
- - - ">="
80
- - !ruby/object:Gem::Version
81
- version: '0'
82
68
  - !ruby/object:Gem::Dependency
83
69
  name: bundler
84
70
  requirement: !ruby/object:Gem::Requirement