autoscale-queue-good_job 0.1.0 → 0.2.0
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/CHANGELOG.md +4 -0
- data/lib/autoscale/queue/good_job/version.rb +1 -1
- data/lib/autoscale/queue/good_job.rb +2 -2
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a00e8e8c6ccde64d519f402afda7ac4b64a30c2657096c56459b411fbe7efad6
|
4
|
+
data.tar.gz: 480abd8505b5817318d8b78231b67f43b7567c219b1dca26dfa3a59434d9e2f8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e71a3f24abd40143b95b9d7fb1909855c64b9944319d82a355101c94ea302bf968c4076f3dc3173eb13e97342a8747bb87311215c12ab7513756ed0dc067f936
|
7
|
+
data.tar.gz: 5d692e486abf365b6109233f504c51d3e603dffcb99f16acd4bacbef8a0164974a64d3c2a0b077c85cc27df471338feab42a06ec03c1f2c7c32a106e556d9b7f
|
data/CHANGELOG.md
CHANGED
@@ -3,14 +3,14 @@ require_relative "good_job/version"
|
|
3
3
|
module Autoscale
|
4
4
|
module Queue
|
5
5
|
module GoodJob
|
6
|
-
def
|
6
|
+
def job_queue_time(*queues)
|
7
7
|
qry = ::GoodJob::Job.select("COALESCE(scheduled_at, created_at) AS run_at")
|
8
8
|
qry = qry.where(queue_name: queues) unless queues.empty?
|
9
9
|
age = qry.queued.order(:run_at).first.try(:run_at)
|
10
10
|
age ? (Time.now - age).round : 0
|
11
11
|
end
|
12
12
|
|
13
|
-
module_function :
|
13
|
+
module_function :job_queue_time
|
14
14
|
end
|
15
15
|
end
|
16
16
|
end
|
metadata
CHANGED
@@ -1,16 +1,16 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: autoscale-queue-good_job
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael R. van Rooijen
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-05-23 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
|
-
description:
|
13
|
+
description:
|
14
14
|
email:
|
15
15
|
- support@autoscale.app
|
16
16
|
executables: []
|
@@ -33,7 +33,7 @@ metadata:
|
|
33
33
|
changelog_uri: https://github.com/autoscale-app/ruby-queue-good_job/blob/master/CHANGELOG.md
|
34
34
|
bug_tracker_uri: https://github.com/autoscale-app/ruby-queue-good_job/issues
|
35
35
|
rubygems_mfa_required: 'true'
|
36
|
-
post_install_message:
|
36
|
+
post_install_message:
|
37
37
|
rdoc_options: []
|
38
38
|
require_paths:
|
39
39
|
- lib
|
@@ -48,8 +48,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
48
48
|
- !ruby/object:Gem::Version
|
49
49
|
version: '0'
|
50
50
|
requirements: []
|
51
|
-
rubygems_version: 3.4.
|
52
|
-
signing_key:
|
51
|
+
rubygems_version: 3.4.10
|
52
|
+
signing_key:
|
53
53
|
specification_version: 4
|
54
54
|
summary: Produces Good Job queue metrics for the Autoscale.app Agent
|
55
55
|
test_files: []
|