resque-pubsub 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/examples/resque-pubsub.rb +12 -0
  2. metadata +7 -6
@@ -0,0 +1,12 @@
1
+ # Put this file in config/initializers to control how resque and resque-pubsub are run
2
+
3
+ rails_root = ENV['RAILS_ROOT'] || File.dirname(__FILE__) + '/../../../..'
4
+ rails_env = ENV['RAILS_ENV'] || 'development'
5
+
6
+ REDIS_CONFIG = YAML.load_file(rails_root + '/config/redis.yml')[rails_env]
7
+ Resque.redis = REDIS_CONFIG["host"] + ':' + REDIS_CONFIG["port"].to_s
8
+
9
+ namespace = ENV['RESQUE_NAMESPACE'] || 'mynamespace' # Edit this to use a different namespace for Resque in the app
10
+ Resque.redis.namespace = namespace
11
+ require "#{rails_root}/vendor/plugins/resque-pubsub/lib/resque/plugins/pubsub/exchange.rb"
12
+ Resque::Plugins::Pubsub::Exchange.pubsub_namespace = 'resque:pubsub' # Edit this to use a different namespace for pubsub
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: resque-pubsub
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
5
- prerelease:
4
+ hash: 31
5
+ prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 1
10
- version: 0.1.1
9
+ - 2
10
+ version: 0.1.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Monica McArthur
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-03-14 00:00:00 -07:00
18
+ date: 2011-04-08 00:00:00 -07:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -47,6 +47,7 @@ files:
47
47
  - Rakefile
48
48
  - MIT-LICENSE
49
49
  - HISTORY.md
50
+ - examples/resque-pubsub.rb
50
51
  - lib/resque/plugins/pubsub/broker.rb
51
52
  - lib/resque/plugins/pubsub/exchange.rb
52
53
  - lib/resque/plugins/pubsub/publisher.rb
@@ -89,7 +90,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
89
90
  requirements: []
90
91
 
91
92
  rubyforge_project:
92
- rubygems_version: 1.5.2
93
+ rubygems_version: 1.3.7
93
94
  signing_key:
94
95
  specification_version: 3
95
96
  summary: A Resque plugin that provides a lightweight publish/subscribe messaging system.