burninator 0.1.0 → 0.5.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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +25 -11
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
- metadata.gz: d2ab5383df34974224a6e7ffef9ef840494605ea
4
- data.tar.gz: cc519f7bb61e1fff82149a24cc8fcbfd3d43175f
3
+ metadata.gz: 8a6ca0ca25b3ae4925d62f5f8e97600f3b511a22
4
+ data.tar.gz: dac893d8b389c01ccb5f6b3bc8ce899afba60f48
5
5
  !binary "U0hBNTEy":
6
- metadata.gz: be185bba1093d74f2a2fbaedc62c3a63a746ceba7b76eef9f7ed65264aa22677423e86731a9823397c64ba3c557b38255825d50daef059c9ccd7afd3a7d50bc6
7
- data.tar.gz: 1db925daaa85812506d1a9489b9d5b41b8a70cfda531271d30af25b5b4f8cd7a5b4c67a05bbb098ecbb5280d85ece6181151befc9fa537596bb66e434f958d56
6
+ metadata.gz: 366d9b17837694c64a3c4181350313c226dc64e59289f21e3e41cbdc96d1e41f11b6a403fbaa2e8c61202578ab2866de83edfd05df465d2f0ff81c0fb82343c2
7
+ data.tar.gz: 77e21271cf69f65aca1f43eae570f0d588a834a1324134f40d9a0d84eb3732a8640543a1c2f454f2f8a640a387af31fc0a8fcb35dc7d17f39952cf3b8a982b6c
data/README.md CHANGED
@@ -1,6 +1,7 @@
1
1
  # burninator
2
2
 
3
3
  [![Code Climate](https://codeclimate.com/github/jpignata/burninator.png)](https://codeclimate.com/github/jpignata/burninator)
4
+ [![Build Status](https://travis-ci.org/jpignata/burninator.png)](https://travis-ci.org/jpignata/burninator)
4
5
  [![Gem Version](https://badge.fury.io/rb/burninator.png)](http://badge.fury.io/rb/burninator)
5
6
 
6
7
  ### Status: Beta (Caveat Utilitor)
@@ -17,42 +18,55 @@ caches are cold you're likely in for a rough time until its SQL and page
17
18
  caches warm up.
18
19
 
19
20
  Burninator uses a Redis pub/sub channel to broadcast some percentage of
20
- query traffic (by default 5%) from Rails application servers to a central
21
+ query traffic from Rails application servers to a central
21
22
  warming process that will run queries against the follower. It uses the
22
- ActiveSupport notifications instrumentation API to listen for queries. These
23
- queries are broadcast through the channel to the warming process which
24
- will run them onto the standby database.
23
+ ActiveSupport notifications instrumentation API to listen for queries.
25
24
 
26
- Since you're standby is seeing some percentage of real production query
25
+ Since your standby is seeing some percentage of real production query
27
26
  traffic, its caches should keep warm and ready for failover.
28
27
 
28
+ ## Requirements
29
+
30
+ * Rails application (only tested against 3.2.12)
31
+ * Redis
32
+
29
33
  ## Installation
30
34
 
31
- Assuming you're using Heroku:
35
+ ### Heroku
36
+
37
+ #### Set your warm target in the environment
38
+
39
+ ```sh
40
+ $ heroku config:add WARM_TARGET_URL="postgres://..."
41
+ ```
32
42
 
33
- In your Gemfile:
43
+ #### Add the gem in your Gemfile
34
44
 
35
45
  ```ruby
36
46
  gem "burninator"
37
47
  ```
38
48
 
39
- In an initializer:
49
+ #### Add `config/initializers/burninator.rb`
40
50
 
41
51
  ```ruby
42
52
  burninator = Burninator.new(redis: $redis, percentage: 25)
43
53
  burninator.broadcast
44
54
  ```
45
55
 
46
- In your Procfile:
56
+ If you leave off the `redis` parameter, it will create a new connection
57
+ using what's configured in the environment as `REDIS_URL`.
58
+
59
+ `percentage` will default to 5%.
60
+
61
+ #### Add the process in your Procfile:
47
62
 
48
63
  ```ruby
49
64
  burninator: rake burninator:warm
50
65
  ```
51
66
 
52
- Deploy and start burninating:
67
+ #### Deploy and start burninating
53
68
 
54
69
  ```sh
55
- $ heroku config:add WARM_TARGET_URL="postgres://..."
56
70
  $ heroku scale burninator=1
57
71
  ```
58
72
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: burninator
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Pignata