hirefire-resource 0.3.11 → 0.3.12
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/README.md +14 -3
- data/hirefire-resource.gemspec +1 -2
- data/lib/hirefire/railtie.rb +1 -1
- metadata +2 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a80653db65155c36c496cd05b0cbf043b833f231
|
|
4
|
+
data.tar.gz: 9702291032d175f36ab02cf6a0696312ddff0d5f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c24af65bb4d692eb26ec8338fda6c1fb448debc1c65fd75f2466147b0b395567b7c182b377085d82aff2913f9584f6297cec5899bbb309378a119d2a3f09d1b8
|
|
7
|
+
data.tar.gz: ea3a9329dd2efb08f24fc10b48fc0f0e38bee8dd4fd6ee595bec6def3ad6f5b5fb9d1ef88dad4263e0922989da46210e6a7f187450baffbfa1b2cc431dd62d28
|
data/README.md
CHANGED
|
@@ -26,13 +26,15 @@ It supports practically any Rack-based application or framework, such as:
|
|
|
26
26
|
We provide convenient macros for the above mentioned worker libraries to calculate the queue size for each of them.
|
|
27
27
|
If you wish to conribute more macros for other existing worker libraries feel free to send us a pull request.
|
|
28
28
|
|
|
29
|
-
Here is an example with Ruby on Rails 3.
|
|
29
|
+
Here is an example with Ruby on Rails 3.
|
|
30
|
+
|
|
31
|
+
First, add the gem to your `Gemfile`:
|
|
30
32
|
|
|
31
33
|
```ruby
|
|
32
34
|
gem "hirefire-resource"
|
|
33
35
|
```
|
|
34
36
|
|
|
35
|
-
Then,
|
|
37
|
+
Then, create an initializer in `config/initializers/hirefire.rb` and add the following:
|
|
36
38
|
|
|
37
39
|
```ruby
|
|
38
40
|
HireFire::Resource.configure do |config|
|
|
@@ -46,6 +48,14 @@ HireFire::Resource.configure do |config|
|
|
|
46
48
|
end
|
|
47
49
|
```
|
|
48
50
|
|
|
51
|
+
Finally, set your `HIREFIRE_TOKEN` environment variable on Heroku. To retrieve your token, visit the [HireFire dashboard](https://manager.hirefire.io/applications) and click your application name.
|
|
52
|
+
```
|
|
53
|
+
heroku config:set HIREFIRE_TOKEN=token --app application_name
|
|
54
|
+
```
|
|
55
|
+
To check that everything is working, you can visit:
|
|
56
|
+
- In development: `localhost:3000/hirefire/development/info`
|
|
57
|
+
- In production: `yourdomain.com/hirefire/your_token/info`
|
|
58
|
+
|
|
49
59
|
This will allow HireFire to read out the queues for both Resque and Delayed Job. By default these macros will count all the queues combined if you are using multiple
|
|
50
60
|
different queues for each worker library. You can also pass in specific queues to count, like so:
|
|
51
61
|
|
|
@@ -56,7 +66,8 @@ HireFire::Resource.configure do |config|
|
|
|
56
66
|
end
|
|
57
67
|
|
|
58
68
|
config.dyno(:dj_worker) do
|
|
59
|
-
HireFire::Macro::Delayed::Job
|
|
69
|
+
HireFire::Macro::Delayed::Job
|
|
70
|
+
.queue(:encode, :compress, mapper: :active_record)
|
|
60
71
|
end
|
|
61
72
|
end
|
|
62
73
|
```
|
data/hirefire-resource.gemspec
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Gem::Specification.new do |gem|
|
|
4
4
|
gem.name = "hirefire-resource"
|
|
5
|
-
gem.version = "0.3.
|
|
5
|
+
gem.version = "0.3.12"
|
|
6
6
|
gem.platform = Gem::Platform::RUBY
|
|
7
7
|
gem.authors = "Michael van Rooijen"
|
|
8
8
|
gem.email = "michael@hirefire.io"
|
|
@@ -15,4 +15,3 @@ Gem::Specification.new do |gem|
|
|
|
15
15
|
gem.executables = ["hirefire", "hirefireapp"]
|
|
16
16
|
gem.require_path = "lib"
|
|
17
17
|
end
|
|
18
|
-
|
data/lib/hirefire/railtie.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: hirefire-resource
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.12
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Michael van Rooijen
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2016-
|
|
11
|
+
date: 2016-10-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies: []
|
|
13
13
|
description: Load- and schedule-based scaling for web- and worker dynos
|
|
14
14
|
email: michael@hirefire.io
|
|
@@ -61,4 +61,3 @@ signing_key:
|
|
|
61
61
|
specification_version: 4
|
|
62
62
|
summary: Autoscaling for your Heroku dynos
|
|
63
63
|
test_files: []
|
|
64
|
-
has_rdoc:
|