hirefire-resource 0.3.11 → 0.3.12

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
  SHA1:
3
- metadata.gz: edafa6801ce37ef1e7f99c64aaaca58d13cf1be2
4
- data.tar.gz: c370334000725171d79789e064af3e2eb2360434
3
+ metadata.gz: a80653db65155c36c496cd05b0cbf043b833f231
4
+ data.tar.gz: 9702291032d175f36ab02cf6a0696312ddff0d5f
5
5
  SHA512:
6
- metadata.gz: 1eb7bd2611991614cab53da79eca09d70c73ecfa620f2a7fc37703cb5b9a976fd7af75048fd3d94c6bfa04e87f34a91edc9af4fdc530d67681828f13cc189afe
7
- data.tar.gz: f20d4740bd5fec0651f6d637f5e615fb83d4fa75fd80f3ffb7b5e34581ae833e2fc43943d01e1c4af422d5097545fe79d6b164624a703d5124698dd20a1be12f
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. First, add the gem to your `Gemfile`:
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, all you have to do is create an initializer in `config/initializers/hirefire.rb` and add the following:
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.queue(:encode, :compress)
69
+ HireFire::Macro::Delayed::Job
70
+ .queue(:encode, :compress, mapper: :active_record)
60
71
  end
61
72
  end
62
73
  ```
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |gem|
4
4
  gem.name = "hirefire-resource"
5
- gem.version = "0.3.11"
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
-
@@ -3,7 +3,7 @@
3
3
  module HireFire
4
4
  class Railtie < ::Rails::Railtie
5
5
  initializer "hirefire.add_middleware" do |app|
6
- app.config.middleware.insert 0, "HireFire::Middleware"
6
+ app.config.middleware.insert 0, HireFire::Middleware
7
7
  end
8
8
  end
9
9
  end
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.11
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-05-27 00:00:00.000000000 Z
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: