judoscale-ruby 1.16.0 → 1.16.1
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 +4 -4
- data/lib/judoscale/platform.rb +4 -4
- data/lib/judoscale/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 34ae9d6c20ce360b79ec19a7bf5b05d121a661a946c5b1363243222c3670bed7
|
|
4
|
+
data.tar.gz: c2c3c460d475f09567ec813a1d0325235c97fa8eca563fd3b191f90460fafc1c
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 060df17397957a4b608073f7e32d391afe634f10c4f35e7580ab3c123755fdf302b56afa069dbf2f3525754cdf50bcbdb5f91cb3cb7d8e4ca1c931af1a4c5fa8
|
|
7
|
+
data.tar.gz: 5294e7f465b63423635281e7ba4e29306fb5adbf6544c5e8b0b6a5ed2075955c0e499ff83ba3b621627053392cb60dbaa0374f4ff6a4c6acfbb1e97d23c2d9eb
|
data/lib/judoscale/platform.rb
CHANGED
|
@@ -59,12 +59,12 @@ module Judoscale
|
|
|
59
59
|
end
|
|
60
60
|
end
|
|
61
61
|
|
|
62
|
-
# Heroku dynos are named "web.2". We collect job metrics from
|
|
63
|
-
# container per process type, so any instance beyond the first is redundant —
|
|
62
|
+
# Heroku dynos are named "web.2" or "worker_5s.2". We collect job metrics from
|
|
63
|
+
# a single container per process type, so any instance beyond the first is redundant —
|
|
64
64
|
# it would only duplicate the queue metrics the first instance already reports.
|
|
65
65
|
class Heroku < Platform
|
|
66
66
|
def redundant_instance?
|
|
67
|
-
match = container.match(/\A[
|
|
67
|
+
match = container.match(/\A[\w-]+\.(\d+)\z/)
|
|
68
68
|
match ? match[1].to_i > 1 : false
|
|
69
69
|
end
|
|
70
70
|
|
|
@@ -78,7 +78,7 @@ module Judoscale
|
|
|
78
78
|
# Scalingo containers are named "web-2", same redundancy rule as Heroku.
|
|
79
79
|
class Scalingo < Platform
|
|
80
80
|
def redundant_instance?
|
|
81
|
-
match = container.match(/\A[
|
|
81
|
+
match = container.match(/\A[\w-]+-(\d+)\z/)
|
|
82
82
|
match ? match[1].to_i > 1 : false
|
|
83
83
|
end
|
|
84
84
|
|
data/lib/judoscale/version.rb
CHANGED