backburner_mailer 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +17 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +22 -0
- data/README.md +105 -0
- data/Rakefile +9 -0
- data/backburner_mailer.gemspec +28 -0
- data/lib/backburner_mailer.rb +138 -0
- data/lib/backburner_mailer/version.rb +3 -0
- data/spec/backburner_mailer_spec.rb +173 -0
- data/spec/spec.opts +1 -0
- data/spec/spec_helper.rb +9 -0
- metadata +143 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 4f3d25f31dcf7eced42eebafe8bcabf23e236e3e
|
4
|
+
data.tar.gz: 95c6e125cd82317ebffcf47514a04c2b23bb3de1
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 46de06c89f64c4b1cb6c56a71724b97c6e30460e22c377e030942cfcd184aa37196518095472873be8d433a11cc8336aee50d59302407915e266757577c6c5f6
|
7
|
+
data.tar.gz: ffe70fd203ca8fc943d326cf9206ef7cab3f97fef25d5163784a4fdbd90cf251ca7ac43154002916e56714367ea3ef7f950e91a1fccab764b3d96a0fc2d63c0f
|
data/.gitignore
ADDED
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
Copyright (c) 2013 Nathan Esquenazi
|
2
|
+
|
3
|
+
MIT License
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
6
|
+
a copy of this software and associated documentation files (the
|
7
|
+
"Software"), to deal in the Software without restriction, including
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
11
|
+
the following conditions:
|
12
|
+
|
13
|
+
The above copyright notice and this permission notice shall be
|
14
|
+
included in all copies or substantial portions of the Software.
|
15
|
+
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
19
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
20
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
21
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
22
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,105 @@
|
|
1
|
+
# BackburnerMailer
|
2
|
+
|
3
|
+
A gem plugin which allows messages prepared by ActionMailer or Padrino Mailer to be delivered
|
4
|
+
asynchronously. Assumes you're using Backburner (http://github.com/nesquena/backburner)
|
5
|
+
for your background jobs.
|
6
|
+
|
7
|
+
Note that Backburner::Mailer only works with Rails 3.x and Padrino.
|
8
|
+
|
9
|
+
This was **heavily** inspired by and largely adapted from [resque-mailer](https://github.com/zapnap/resque_mailer).
|
10
|
+
Most of the credit goes to them, this is a minor adaptation to support backburner.
|
11
|
+
|
12
|
+
## Usage
|
13
|
+
|
14
|
+
Include Backburner::Mailer in your ActionMailer subclass(es) like this:
|
15
|
+
|
16
|
+
```ruby
|
17
|
+
class MyMailer < ActionMailer::Base
|
18
|
+
include Backburner::Mailer
|
19
|
+
end
|
20
|
+
```
|
21
|
+
|
22
|
+
Now, when `MyMailer.subject_email(params).deliver` is called, an entry
|
23
|
+
will be created in the job queue. Your Backburner workers will be able to deliver
|
24
|
+
this message for you. The queue we're using is named +mailer+,
|
25
|
+
so just make sure your workers know about it and are loading your environment:
|
26
|
+
|
27
|
+
```bash
|
28
|
+
QUEUE=mailer bundle exec rake backburner:work
|
29
|
+
```
|
30
|
+
|
31
|
+
Note that you can still have mail delivered synchronously by using the bang
|
32
|
+
method variant:
|
33
|
+
|
34
|
+
```ruby
|
35
|
+
MyMailer.subject_email(params).deliver!
|
36
|
+
```
|
37
|
+
|
38
|
+
Oh, by the way. Don't forget that **your async mailer jobs will be processed by
|
39
|
+
a separate worker**. This means that you should resist the temptation to pass
|
40
|
+
database-backed objects as parameters in your mailer and instead pass record
|
41
|
+
identifiers. Then, in your delivery method, you can look up the record from
|
42
|
+
the id and use it as needed.
|
43
|
+
|
44
|
+
If you want to set a different default queue name for your mailer, you can
|
45
|
+
change the `default_queue_name` property like so:
|
46
|
+
|
47
|
+
```ruby
|
48
|
+
# config/initializers/backburner_mailer.rb
|
49
|
+
Backburner::Mailer.default_queue_name = 'application_specific_mailer'
|
50
|
+
```
|
51
|
+
|
52
|
+
This is useful when you are running more than one application using
|
53
|
+
backburner_mailer in a shared environment. You will need to use the new queue
|
54
|
+
name when starting your workers.
|
55
|
+
|
56
|
+
```bash
|
57
|
+
QUEUE=application_specific_mailer bundle exec rake backburner:work
|
58
|
+
```
|
59
|
+
|
60
|
+
Custom handling of errors that arise when sending a message is possible by
|
61
|
+
assigning a lambda to the `error_hander` attribute.
|
62
|
+
|
63
|
+
```ruby
|
64
|
+
Backburner::Mailer.error_handler = lambda { |mailer, message, error|
|
65
|
+
# some custom error handling code here in which you optionally re-raise the error
|
66
|
+
}
|
67
|
+
```
|
68
|
+
|
69
|
+
## Installation
|
70
|
+
|
71
|
+
Install the gem:
|
72
|
+
|
73
|
+
gem install backburner_mailer
|
74
|
+
|
75
|
+
If you're using Bundler to manage your dependencies, you should add it to your Gemfile:
|
76
|
+
|
77
|
+
gem 'backburner'
|
78
|
+
gem 'backburner_mailer'
|
79
|
+
|
80
|
+
## Testing
|
81
|
+
|
82
|
+
You don't want to be sending actual emails in the test environment, so you can
|
83
|
+
configure the environments that should be excluded like so:
|
84
|
+
|
85
|
+
# config/initializers/backburner_mailer.rb
|
86
|
+
Backburner::Mailer.excluded_environments = [:test, :cucumber]
|
87
|
+
|
88
|
+
Note: Define `current_env` if using Backburner::Mailer in a non-Rails or non-Padrino project:
|
89
|
+
|
90
|
+
Backburner::Mailer.current_env = :production
|
91
|
+
|
92
|
+
## Note on Patches / Pull Requests
|
93
|
+
|
94
|
+
* Fork the project.
|
95
|
+
* Make your feature addition or bug fix.
|
96
|
+
* Add tests for it. This is important so I don't break it in a future version unintentionally.
|
97
|
+
* Commit, do not mess with rakefile, version, or history.
|
98
|
+
(if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
|
99
|
+
* Send me a pull request. Bonus points for topic branches.
|
100
|
+
|
101
|
+
## Credits
|
102
|
+
|
103
|
+
Developed by Nathan Esquenazi.
|
104
|
+
Shamelessly adapted from [resque-mailer](https://github.com/zapnap/resque_mailer).
|
105
|
+
Code originally developed by Nick Plante with help from a number of [contributors](https://github.com/zapnap/resque_mailer/contributors).
|
data/Rakefile
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'backburner_mailer/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "backburner_mailer"
|
8
|
+
spec.version = BackburnerMailer::VERSION
|
9
|
+
spec.authors = ["Nathan Esquenazi"]
|
10
|
+
spec.email = ["nesquena@gmail.com"]
|
11
|
+
spec.description = %q{Plugin for sending asynchronous email with Backburner}
|
12
|
+
spec.summary = %q{Plugin for sending asynchronous email with Backburner.}
|
13
|
+
spec.homepage = "https://github.com/nesquena/backburner_mailer"
|
14
|
+
spec.license = "MIT"
|
15
|
+
|
16
|
+
spec.files = `git ls-files`.split($/)
|
17
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
|
+
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
+
spec.require_paths = ["lib"]
|
20
|
+
|
21
|
+
spec.add_runtime_dependency "backburner"
|
22
|
+
|
23
|
+
spec.add_development_dependency "bundler", "~> 1.3"
|
24
|
+
spec.add_development_dependency "rake"
|
25
|
+
spec.add_development_dependency "actionmailer", "~> 3"
|
26
|
+
spec.add_development_dependency("rspec", "~> 2.6")
|
27
|
+
spec.add_development_dependency("yard", ">= 0.6.0")
|
28
|
+
end
|
@@ -0,0 +1,138 @@
|
|
1
|
+
require "backburner_mailer/version"
|
2
|
+
|
3
|
+
module Backburner
|
4
|
+
module Mailer
|
5
|
+
class << self
|
6
|
+
attr_accessor :default_queue_name, :default_queue_target, :current_env, :logger, :fallback_to_synchronous, :error_handler
|
7
|
+
attr_reader :excluded_environments
|
8
|
+
|
9
|
+
def excluded_environments=(envs)
|
10
|
+
@excluded_environments = [*envs].map { |e| e.to_sym }
|
11
|
+
end
|
12
|
+
|
13
|
+
def included(base)
|
14
|
+
base.send(:include, Backburner::Queue)
|
15
|
+
base.extend(ClassMethods)
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
self.logger = nil
|
20
|
+
self.default_queue_target = ::Backburner
|
21
|
+
self.default_queue_name = "mailer"
|
22
|
+
self.excluded_environments = []
|
23
|
+
|
24
|
+
module ClassMethods
|
25
|
+
|
26
|
+
def current_env
|
27
|
+
if defined?(Rails)
|
28
|
+
::Backburner::Mailer.current_env || ::Rails.env
|
29
|
+
elsif defined?(Padrino)
|
30
|
+
::Backburner::Mailer.current_env || ::Padrino.env
|
31
|
+
else
|
32
|
+
::Backburner::Mailer.current_env
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
36
|
+
def method_missing(method_name, *args)
|
37
|
+
if action_methods.include?(method_name.to_s)
|
38
|
+
MessageDecoy.new(self, method_name, *args)
|
39
|
+
else
|
40
|
+
super
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
def perform(action, *args)
|
45
|
+
begin
|
46
|
+
message = self.send(:new, action, *args).message
|
47
|
+
message.deliver
|
48
|
+
rescue Exception => ex
|
49
|
+
if Mailer.error_handler
|
50
|
+
Mailer.error_handler.call(self, message, ex)
|
51
|
+
else
|
52
|
+
if logger
|
53
|
+
logger.error "Unable to deliver email [#{action}]: #{ex}"
|
54
|
+
logger.error ex.backtrace.join("\n\t")
|
55
|
+
end
|
56
|
+
raise ex
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
61
|
+
def queue
|
62
|
+
@queue || ::Backburner::Mailer.default_queue_name
|
63
|
+
end
|
64
|
+
|
65
|
+
def queue=(name)
|
66
|
+
@queue = name
|
67
|
+
end
|
68
|
+
|
69
|
+
def backburner
|
70
|
+
::Backburner::Mailer.default_queue_target
|
71
|
+
end
|
72
|
+
|
73
|
+
def excluded_environment?(name)
|
74
|
+
::Backburner::Mailer.excluded_environments && ::Backburner::Mailer.excluded_environments.include?(name.try(:to_sym))
|
75
|
+
end
|
76
|
+
|
77
|
+
def deliver?
|
78
|
+
true
|
79
|
+
end
|
80
|
+
end
|
81
|
+
|
82
|
+
class MessageDecoy
|
83
|
+
delegate :to_s, :to => :actual_message
|
84
|
+
|
85
|
+
def initialize(mailer_class, method_name, *args)
|
86
|
+
@mailer_class = mailer_class
|
87
|
+
@method_name = method_name
|
88
|
+
*@args = *args
|
89
|
+
end
|
90
|
+
|
91
|
+
def backburner
|
92
|
+
::Backburner::Mailer.default_queue_target
|
93
|
+
end
|
94
|
+
|
95
|
+
def current_env
|
96
|
+
if defined?(Rails)
|
97
|
+
::Backburner::Mailer.current_env || ::Rails.env
|
98
|
+
elsif defined?(Padrino)
|
99
|
+
::Backburner::Mailer.current_env || ::Padrino.env
|
100
|
+
else
|
101
|
+
::Backburner::Mailer.current_env
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
def environment_excluded?
|
106
|
+
!ActionMailer::Base.perform_deliveries || excluded_environment?(current_env)
|
107
|
+
end
|
108
|
+
|
109
|
+
def excluded_environment?(name)
|
110
|
+
::Backburner::Mailer.excluded_environments && ::Backburner::Mailer.excluded_environments.include?(name.to_sym)
|
111
|
+
end
|
112
|
+
|
113
|
+
def actual_message
|
114
|
+
@actual_message ||= @mailer_class.send(:new, @method_name, *@args).message
|
115
|
+
end
|
116
|
+
|
117
|
+
def deliver
|
118
|
+
return deliver! if environment_excluded?
|
119
|
+
|
120
|
+
if @mailer_class.deliver?
|
121
|
+
begin
|
122
|
+
backburner.enqueue(@mailer_class, @method_name, *@args)
|
123
|
+
rescue Errno::ECONNREFUSED
|
124
|
+
deliver!
|
125
|
+
end
|
126
|
+
end
|
127
|
+
end
|
128
|
+
|
129
|
+
def deliver!
|
130
|
+
actual_message.deliver
|
131
|
+
end
|
132
|
+
|
133
|
+
def method_missing(method_name, *args)
|
134
|
+
actual_message.send(method_name, *args)
|
135
|
+
end
|
136
|
+
end
|
137
|
+
end
|
138
|
+
end
|
@@ -0,0 +1,173 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
class FakeBackburner
|
4
|
+
def self.enqueue(*args); end
|
5
|
+
end
|
6
|
+
|
7
|
+
class Rails3Mailer < ActionMailer::Base
|
8
|
+
include Backburner::Mailer
|
9
|
+
default :from => "from@example.org", :subject => "Subject"
|
10
|
+
MAIL_PARAMS = { :to => "crafty@example.org" }
|
11
|
+
|
12
|
+
def test_mail(*params)
|
13
|
+
Backburner::Mailer.success!
|
14
|
+
mail(*params)
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
class PriorityMailer < Rails3Mailer
|
19
|
+
self.queue = 'priority_mailer'
|
20
|
+
end
|
21
|
+
|
22
|
+
describe Backburner::Mailer do
|
23
|
+
let(:backburner) { FakeBackburner }
|
24
|
+
|
25
|
+
before do
|
26
|
+
Backburner::Mailer.default_queue_target = backburner
|
27
|
+
Backburner::Mailer.fallback_to_synchronous = false
|
28
|
+
Backburner::Mailer.stub(:success!)
|
29
|
+
Backburner::Mailer.stub(:current_env => :test)
|
30
|
+
end
|
31
|
+
|
32
|
+
describe "backburner" do
|
33
|
+
it "allows overriding of the default queue target (for testing)" do
|
34
|
+
Backburner::Mailer.default_queue_target = FakeBackburner
|
35
|
+
Rails3Mailer.backburner.should == FakeBackburner
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
describe "queue" do
|
40
|
+
it "defaults to the 'mailer' queue" do
|
41
|
+
Rails3Mailer.queue.should == "mailer"
|
42
|
+
end
|
43
|
+
|
44
|
+
it "allows overriding of the default queue name" do
|
45
|
+
Backburner::Mailer.default_queue_name = "postal"
|
46
|
+
Rails3Mailer.queue.should == "postal"
|
47
|
+
end
|
48
|
+
|
49
|
+
it "allows overriding of the local queue name" do
|
50
|
+
PriorityMailer.queue.should == "priority_mailer"
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
describe '#deliver' do
|
55
|
+
before(:all) do
|
56
|
+
@delivery = lambda {
|
57
|
+
Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).deliver
|
58
|
+
}
|
59
|
+
end
|
60
|
+
|
61
|
+
it 'should not deliver the email synchronously' do
|
62
|
+
lambda { @delivery.call }.should_not change(ActionMailer::Base.deliveries, :size)
|
63
|
+
end
|
64
|
+
|
65
|
+
it 'should place the deliver action on the Backburner "mailer" queue' do
|
66
|
+
backburner.should_receive(:enqueue).with(Rails3Mailer, :test_mail, Rails3Mailer::MAIL_PARAMS)
|
67
|
+
@delivery.call
|
68
|
+
end
|
69
|
+
|
70
|
+
context "when current env is excluded" do
|
71
|
+
it 'should not deliver through Backburner for excluded environments' do
|
72
|
+
Backburner::Mailer.stub(:excluded_environments => [:custom])
|
73
|
+
Backburner::Mailer::MessageDecoy.any_instance.should_receive(:current_env).and_return(:custom)
|
74
|
+
backburner.should_not_receive(:enqueue)
|
75
|
+
@delivery.call
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
79
|
+
it 'should not invoke the method body more than once' do
|
80
|
+
Backburner::Mailer.should_not_receive(:success!)
|
81
|
+
Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).deliver
|
82
|
+
end
|
83
|
+
|
84
|
+
context "when fallback_to_synchronous is true" do
|
85
|
+
before do
|
86
|
+
Backburner::Mailer.fallback_to_synchronous = true
|
87
|
+
end
|
88
|
+
|
89
|
+
context "when redis is not available" do
|
90
|
+
before do
|
91
|
+
Backburner::Mailer.default_queue_target.stub(:enqueue).and_raise(Errno::ECONNREFUSED)
|
92
|
+
end
|
93
|
+
|
94
|
+
it 'should deliver the email synchronously' do
|
95
|
+
lambda { @delivery.call }.should change(ActionMailer::Base.deliveries, :size).by(1)
|
96
|
+
end
|
97
|
+
end
|
98
|
+
end
|
99
|
+
end
|
100
|
+
|
101
|
+
describe '#deliver!' do
|
102
|
+
it 'should deliver the email synchronously' do
|
103
|
+
lambda { Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).deliver! }.should change(ActionMailer::Base.deliveries, :size).by(1)
|
104
|
+
end
|
105
|
+
end
|
106
|
+
|
107
|
+
describe 'perform' do
|
108
|
+
it 'should perform a queued mailer job' do
|
109
|
+
lambda {
|
110
|
+
Rails3Mailer.perform(:test_mail, Rails3Mailer::MAIL_PARAMS)
|
111
|
+
}.should change(ActionMailer::Base.deliveries, :size).by(1)
|
112
|
+
end
|
113
|
+
|
114
|
+
context "when job fails" do
|
115
|
+
let(:message) { mock(:message) }
|
116
|
+
let(:mailer) { mock(:mailer, :message => message) }
|
117
|
+
let(:logger) { mock(:logger, :error => nil) }
|
118
|
+
let(:exception) { Exception.new("An error") }
|
119
|
+
|
120
|
+
before(:each) do
|
121
|
+
Backburner::Mailer.error_handler = nil
|
122
|
+
Rails3Mailer.logger = logger
|
123
|
+
Rails3Mailer.stub(:new) { mailer }
|
124
|
+
message.stub(:deliver).and_raise(exception)
|
125
|
+
end
|
126
|
+
|
127
|
+
subject { Rails3Mailer.perform(:test_mail, Rails3Mailer::MAIL_PARAMS) }
|
128
|
+
|
129
|
+
it "raises and logs the exception" do
|
130
|
+
logger.should_receive(:error).at_least(:once)
|
131
|
+
expect { subject }.to raise_error
|
132
|
+
end
|
133
|
+
|
134
|
+
context "when error_handler set" do
|
135
|
+
before(:each) do
|
136
|
+
Backburner::Mailer.error_handler = lambda { |mailer, message, exception|
|
137
|
+
@mailer = mailer
|
138
|
+
@message = message
|
139
|
+
@exception = exception
|
140
|
+
}
|
141
|
+
end
|
142
|
+
|
143
|
+
it "should pass the mailer to the handler" do
|
144
|
+
subject
|
145
|
+
@mailer.should eq(Rails3Mailer)
|
146
|
+
end
|
147
|
+
|
148
|
+
it "should pass the message to the handler" do
|
149
|
+
subject
|
150
|
+
@message.should eq(message)
|
151
|
+
end
|
152
|
+
|
153
|
+
it "should pass the exception to the handler" do
|
154
|
+
subject
|
155
|
+
@exception.should eq(exception)
|
156
|
+
end
|
157
|
+
end
|
158
|
+
end
|
159
|
+
end
|
160
|
+
|
161
|
+
describe 'original mail methods' do
|
162
|
+
it 'should be preserved' do
|
163
|
+
Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).subject.should == 'Subject'
|
164
|
+
Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).from.should include('from@example.org')
|
165
|
+
Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).to.should include('crafty@example.org')
|
166
|
+
end
|
167
|
+
|
168
|
+
it 'should require execution of the method body prior to queueing' do
|
169
|
+
Backburner::Mailer.should_receive(:success!).once
|
170
|
+
Rails3Mailer.test_mail(Rails3Mailer::MAIL_PARAMS).subject
|
171
|
+
end
|
172
|
+
end
|
173
|
+
end
|
data/spec/spec.opts
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
--color
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,9 @@
|
|
1
|
+
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
2
|
+
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
3
|
+
|
4
|
+
require 'action_mailer'
|
5
|
+
require 'backburner_mailer'
|
6
|
+
require 'rspec/autorun'
|
7
|
+
|
8
|
+
Backburner::Mailer.excluded_environments = []
|
9
|
+
ActionMailer::Base.delivery_method = :test
|
metadata
ADDED
@@ -0,0 +1,143 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: backburner_mailer
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Nathan Esquenazi
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2013-04-19 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: backburner
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - '>='
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - '>='
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: bundler
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ~>
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '1.3'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ~>
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '1.3'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rake
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - '>='
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - '>='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: actionmailer
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ~>
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '3'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ~>
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '3'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rspec
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ~>
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '2.6'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ~>
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '2.6'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: yard
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - '>='
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 0.6.0
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - '>='
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 0.6.0
|
97
|
+
description: Plugin for sending asynchronous email with Backburner
|
98
|
+
email:
|
99
|
+
- nesquena@gmail.com
|
100
|
+
executables: []
|
101
|
+
extensions: []
|
102
|
+
extra_rdoc_files: []
|
103
|
+
files:
|
104
|
+
- .gitignore
|
105
|
+
- Gemfile
|
106
|
+
- LICENSE.txt
|
107
|
+
- README.md
|
108
|
+
- Rakefile
|
109
|
+
- backburner_mailer.gemspec
|
110
|
+
- lib/backburner_mailer.rb
|
111
|
+
- lib/backburner_mailer/version.rb
|
112
|
+
- spec/backburner_mailer_spec.rb
|
113
|
+
- spec/spec.opts
|
114
|
+
- spec/spec_helper.rb
|
115
|
+
homepage: https://github.com/nesquena/backburner_mailer
|
116
|
+
licenses:
|
117
|
+
- MIT
|
118
|
+
metadata: {}
|
119
|
+
post_install_message:
|
120
|
+
rdoc_options: []
|
121
|
+
require_paths:
|
122
|
+
- lib
|
123
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
124
|
+
requirements:
|
125
|
+
- - '>='
|
126
|
+
- !ruby/object:Gem::Version
|
127
|
+
version: '0'
|
128
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
129
|
+
requirements:
|
130
|
+
- - '>='
|
131
|
+
- !ruby/object:Gem::Version
|
132
|
+
version: '0'
|
133
|
+
requirements: []
|
134
|
+
rubyforge_project:
|
135
|
+
rubygems_version: 2.0.2
|
136
|
+
signing_key:
|
137
|
+
specification_version: 4
|
138
|
+
summary: Plugin for sending asynchronous email with Backburner.
|
139
|
+
test_files:
|
140
|
+
- spec/backburner_mailer_spec.rb
|
141
|
+
- spec/spec.opts
|
142
|
+
- spec/spec_helper.rb
|
143
|
+
has_rdoc:
|