harness-active_publisher 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/harness-active_publisher.gemspec +1 -1
- data/lib/harness/active_publisher.rb +10 -5
- data/lib/harness/active_publisher/version.rb +1 -1
- metadata +7 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1eca2ee805cae19685fd8b6d3c8c53d2e16f73c1f36990c98a54281ab05ddc1b
|
4
|
+
data.tar.gz: 968c02b888552aed50543a481ab4d1aabee73137af93c441a89d8608f7520eaf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f76be7663cbc73e73182b9a990a89217242e7f40bd5200a089c43a83eb9d22d79d4e294db1c1b377c199422ce2c3ad4389e61a740327d93f852ebe07b7f69b7d
|
7
|
+
data.tar.gz: cbabaf8e8ec1c4f9d50ffbc93969e1c4423ce31dffb371a1dddbb33264080160a767d4bdbaf12c4e72e1503dbf9716f83ad739373151a3fd93923f1054ade136
|
@@ -25,6 +25,6 @@ Gem::Specification.new do |spec|
|
|
25
25
|
spec.add_runtime_dependency "harness", ">= 2.0.0"
|
26
26
|
|
27
27
|
spec.add_development_dependency "bundler"
|
28
|
-
spec.add_development_dependency "rake", "
|
28
|
+
spec.add_development_dependency "rake", ">= 12.3.3"
|
29
29
|
spec.add_development_dependency "rspec", "~> 3.0"
|
30
30
|
end
|
@@ -5,16 +5,21 @@ require "active_support"
|
|
5
5
|
|
6
6
|
module Harness
|
7
7
|
module ActivePublisher
|
8
|
-
DROPPED_METRIC
|
9
|
-
LATENCY_METRIC
|
10
|
-
PUBLISHED_METRIC
|
11
|
-
QUEUE_SIZE_METRIC
|
12
|
-
|
8
|
+
DROPPED_METRIC = ["active_publisher", ENV["SERVICE_NAME"], "message_dropped"].reject(&:nil?).join(".").freeze
|
9
|
+
LATENCY_METRIC = ["active_publisher", ENV["SERVICE_NAME"], "publish_latency"].reject(&:nil?).join(".").freeze
|
10
|
+
PUBLISHED_METRIC = ["active_publisher", ENV["SERVICE_NAME"], "messages_published"].reject(&:nil?).join(".").freeze
|
11
|
+
QUEUE_SIZE_METRIC = ["active_publisher", ENV["SERVICE_NAME"], "async_queue_size"].reject(&:nil?).join(".").freeze
|
12
|
+
REDIS_QUEUE_SIZE_METRIC = ["active_publisher", ENV["SERVICE_NAME"], "redis_async_queue_size"].reject(&:nil?).join(".").freeze
|
13
|
+
WAIT_METRIC = ["active_publisher", ENV["SERVICE_NAME"], "waiting_for_async_queue"].reject(&:nil?).join(".").freeze
|
13
14
|
|
14
15
|
::ActiveSupport::Notifications.subscribe "async_queue_size.active_publisher" do |_, _, _, _, async_queue_size|
|
15
16
|
::Harness.gauge QUEUE_SIZE_METRIC, async_queue_size
|
16
17
|
end
|
17
18
|
|
19
|
+
::ActiveSupport::Notifications.subscribe "redis_async_queue_size.active_publisher" do |_, _, _, _, redis_async_queue_size|
|
20
|
+
::Harness.gauge REDIS_QUEUE_SIZE_METRIC, redis_async_queue_size
|
21
|
+
end
|
22
|
+
|
18
23
|
::ActiveSupport::Notifications.subscribe "message_dropped.active_publisher" do
|
19
24
|
::Harness.increment DROPPED_METRIC
|
20
25
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: harness-active_publisher
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Ries
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-05-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -56,16 +56,16 @@ dependencies:
|
|
56
56
|
name: rake
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: 12.3.3
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: 12.3.3
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rspec
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -120,8 +120,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
120
120
|
- !ruby/object:Gem::Version
|
121
121
|
version: '0'
|
122
122
|
requirements: []
|
123
|
-
|
124
|
-
rubygems_version: 2.7.6
|
123
|
+
rubygems_version: 3.1.2
|
125
124
|
signing_key:
|
126
125
|
specification_version: 4
|
127
126
|
summary: a gem to collect instrumation stats from active_publisher and forward them
|