sidekiq-cloudwatchmetrics 2.2.0 → 2.3.1

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: fb8deb7fa07fddb75c82ec3b631a803c0d12bb67176e4c210675be9e5b5e2206
4
- data.tar.gz: d4ea3bb0ecec06fdbe5e52f95f1bef2505bbc89550346301f5720f1750944335
3
+ metadata.gz: 93c28ff2cfaca3875a7519787116e4d1e748485a697432b4dd92659e167bf6cf
4
+ data.tar.gz: f1ba283d86ad4626910f0ead50d5d30868d7f491c970e38d6fbf0c0641562b30
5
5
  SHA512:
6
- metadata.gz: f9568afd5661bb2f0520f109cbe671d85880cf834b919ee20813e7980bcee4426559b654596e352c23e3e3e5c1c5de8e7ffe918402d17aee225f59d122323a80
7
- data.tar.gz: f4f68b369bc2cea9f565346f103cff7c1323bf05aa80572181b3a11100b7276ec999bd5b22f15261de000d0c6e33be52d17d80a70b5ec01c0267c9483b3d4a89
6
+ metadata.gz: b85fa07e697fd3e993cd2e73dd177c2ba1409ca5bd0456592459aff97606dfbe981a085a51cba50c27e9220bbec9c3efd2035dd0c47f4b159be075d56338f78d
7
+ data.tar.gz: b56863b700fb48a48553895383dc3c9a6884a12515891baa61d2d3e8181fa51add282bd156fc08ea9a64705e009e160397d1c1104936fb0209e8e7916e930bac
checksums.yaml.gz.sig CHANGED
Binary file
@@ -2,7 +2,6 @@
2
2
 
3
3
  require "sidekiq"
4
4
  require "sidekiq/api"
5
- require "sidekiq/util"
6
5
 
7
6
  require "aws-sdk-cloudwatch"
8
7
 
@@ -11,8 +10,9 @@ module Sidekiq::CloudWatchMetrics
11
10
  Sidekiq.configure_server do |config|
12
11
  publisher = Publisher.new(**kwargs)
13
12
 
14
- if Sidekiq.options[:lifecycle_events].has_key?(:leader)
15
- # Only publish metrics on the leader if we have a leader (sidekiq-ent)
13
+ # Sidekiq enterprise has a globally unique leader thread, making it
14
+ # easier to publish the cluster-wide metrics from one place.
15
+ if defined?(Sidekiq::Enterprise)
16
16
  config.on(:leader) do
17
17
  publisher.start
18
18
  end
@@ -34,11 +34,21 @@ module Sidekiq::CloudWatchMetrics
34
34
  end
35
35
 
36
36
  class Publisher
37
- include Sidekiq::Util
37
+ begin
38
+ require "sidekiq/util"
39
+ include Sidekiq::Util
40
+ rescue LoadError
41
+ # Sidekiq 6.5 refactored to use Sidekiq::Component
42
+ require "sidekiq/component"
43
+ include Sidekiq::Component
44
+ end
38
45
 
39
46
  INTERVAL = 60 # seconds
40
47
 
41
- def initialize(client: Aws::CloudWatch::Client.new, namespace: "Sidekiq", additional_dimensions: {})
48
+ def initialize(config: Sidekiq, client: Aws::CloudWatch::Client.new, namespace: "Sidekiq", additional_dimensions: {})
49
+ # Sidekiq 6.5+ requires @config, which defaults to the top-level
50
+ # `Sidekiq` module, but can be overridden when running multiple Sidekiqs.
51
+ @config = config
42
52
  @client = client
43
53
  @namespace = namespace
44
54
  @additional_dimensions = additional_dimensions.map { |k, v| {name: k.to_s, value: v.to_s} }
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq-cloudwatchmetrics
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.0
4
+ version: 2.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Cochran
@@ -10,25 +10,26 @@ bindir: bin
10
10
  cert_chain:
11
11
  - |
12
12
  -----BEGIN CERTIFICATE-----
13
- MIIDKDCCAhCgAwIBAgIBCDANBgkqhkiG9w0BAQsFADA6MQ0wCwYDVQQDDARzajI2
13
+ MIIDXDCCAkSgAwIBAgIBATANBgkqhkiG9w0BAQsFADA6MQ0wCwYDVQQDDARzajI2
14
14
  MRQwEgYKCZImiZPyLGQBGRYEc2oyNjETMBEGCgmSJomT8ixkARkWA2NvbTAeFw0y
15
- MTA0MjcwMzIxMjZaFw0yMjA0MjcwMzIxMjZaMDoxDTALBgNVBAMM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zLrN9u09kuWLLJfXB2sGOlw3n9t72rJiuBr3/OQQIDAQABo20w
23
+ azAJBgNVHRMEAjAAMAsGA1UdDwQEAwIEsDAdBgNVHQ4EFgQU99dfRjEKFyczTeIz
24
+ m3ZsDWrNC80wGAYDVR0RBBEwD4ENc2oyNkBzajI2LmNvbTAYBgNVHRIEETAPgQ1z
25
+ ajI2QHNqMjYuY29tMA0GCSqGSIb3DQEBCwUAA4IBAQCsa7k3TABBcyXotr3yCq6f
26
+ xsgbMG9FR71c4wRgVNQi9O3jN64fQBbxo//BQlHfPCjs1CeU4es9xdQFfhqXAPXG
27
+ P7mK3+qd5jObjh6l3/rDKrTXNS+P+YO/1frlZ6xPjCA8XgGc4y0rhAjZnVBDV6t1
28
+ kmdtEmue1s1OxaMakr78XRZDxEuAeLM5fg8MYnlOFygEcAH6lZkTjXavY7s9MXRB
29
+ AAMioxgB6J5QhXQ42OSWIzwHZIbSv3DV9Lf5sde50HIW5f9u5jn29TUGDhSWYKkh
30
+ LDvy9dfwMMOdIZi75Q8SBBib84AuwhMHIlUv9FcHhh3dXsDDYkrVrpUAwCsG6yCm
30
31
  -----END CERTIFICATE-----
31
- date: 2022-02-24 00:00:00.000000000 Z
32
+ date: 2023-01-24 00:00:00.000000000 Z
32
33
  dependencies:
33
34
  - !ruby/object:Gem::Dependency
34
35
  name: sidekiq
@@ -39,7 +40,7 @@ dependencies:
39
40
  version: '5.0'
40
41
  - - "<"
41
42
  - !ruby/object:Gem::Version
42
- version: '7.0'
43
+ version: '8.0'
43
44
  type: :runtime
44
45
  prerelease: false
45
46
  version_requirements: !ruby/object:Gem::Requirement
@@ -49,7 +50,7 @@ dependencies:
49
50
  version: '5.0'
50
51
  - - "<"
51
52
  - !ruby/object:Gem::Version
52
- version: '7.0'
53
+ version: '8.0'
53
54
  - !ruby/object:Gem::Dependency
54
55
  name: aws-sdk-cloudwatch
55
56
  requirement: !ruby/object:Gem::Requirement
metadata.gz.sig CHANGED
@@ -1,2 +1,3 @@
1
- �qJ�O�@B���gQ?W���\�W�Q������V�ͿM�CV�U�����c�2�e��8Ay�u�/oF�����ʝ����K�;�� \����?�\"�}7�"~�̎HA�%O-�S9 �I�|��#�LX�q��,N���}4�i��N]���.��0vFSkt^���47�
2
-
1
+ 5�J�~�;�lCm���Ǐ�c����d��z�q�&��l ��E�����3X
2
+ ͜��O'=��7�*HYh�sT�^_�
3
+ }R���1�0�t�1�trX1rzIx>�09��<%��.��.�"��1Oi�WvK~��E��U��.����[.�����>�ث���&μ9W��� �