acidic_job 1.0.0.beta.2 → 1.0.0.beta.3

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
  SHA256:
3
- metadata.gz: d0e5e42007b9069a560d15f86869a6ba8efb9a45866b39d1ba761917f81188ba
4
- data.tar.gz: bdfe50d3598ed4466e9c9b5033e53619e0a4c43fb7dbc3c8b869876ad9d57f40
3
+ metadata.gz: ae3f13ed2a45c147047c0f09348bd4e9d5b4ecca9ca87230b1cacdaf0c371102
4
+ data.tar.gz: f3078b9df6b56f27aad3ed4e18cd361d5f735e871513dd308fdc2d6c18e767de
5
5
  SHA512:
6
- metadata.gz: 17c7a98093f52614d0c071ef947f2fe6ea361843d3f0d494451b4f77966e3d67d1a53ef37ad75bc229a97ccb898a3cb2d193642f5bae906cd333181e34177f48
7
- data.tar.gz: be58b523f666a0d0bec5adef39929441cc1cedc7e0b9f2d5f6cb3ba541284b4ba6b33c76e5a03afa6129fd0ac4658753d2b8d2a210b7be5b1c9847e98478c10e
6
+ metadata.gz: 37063209e88853721910ab7f0952348c20471eb334327cc18e13a7e688314c813541d6ade50e19934919e5de7126d6e888d1f4b90ebb89a61bc978079d121de0
7
+ data.tar.gz: 99c717f971401a1e6034c31a7816d3ffa2b31fc91bff705aa408c61a27c172d9f49907bdc44c96563c8276162a03b1eac9b6ceae1da7614b159e530978e2d1de
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- acidic_job (1.0.0.beta.2)
4
+ acidic_job (1.0.0.beta.3)
5
5
  activejob
6
6
  activerecord
7
7
  activesupport
@@ -14,12 +14,6 @@ module AcidicJob
14
14
  # and run perform callbacks for Sidekiq workers
15
15
  other.prepend PerformWrapper
16
16
 
17
- # Add `deliver_acidicly` to ActionMailer
18
- ::ActionMailer::Parameterized::MessageDelivery.include(Extensions::ActionMailer) if defined?(::ActionMailer)
19
- ::ActionMailer::MessageDelivery.include(Extensions::ActionMailer) if defined?(::ActionMailer)
20
- # Add `deliver_acidicly` to Noticed
21
- ::Noticed::Base.include(Extensions::Noticed) if defined?(::Noticed)
22
-
23
17
  # By default, we unique job runs by the `job_id`
24
18
  other.instance_variable_set(:@acidic_identifier, :job_id)
25
19
  # However, you can customize this behavior on a per job class level
@@ -0,0 +1,29 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "rails/railtie"
4
+
5
+ module AcidicJob
6
+ class Rails < ::Rails::Railtie
7
+ initializer "acidic_job.action_mailer_extension" do
8
+ ActiveSupport.on_load(:action_mailer) do
9
+ # Add `deliver_acidicly` to ActionMailer
10
+ if defined?(::ActionMailer)
11
+ ::ActionMailer::Parameterized::MessageDelivery.include(::AcidicJob::Extensions::ActionMailer)
12
+ end
13
+ ::ActionMailer::MessageDelivery.include(::AcidicJob::Extensions::ActionMailer) if defined?(::ActionMailer)
14
+ end
15
+ end
16
+
17
+ generators do
18
+ require "generators/acidic_job/install_generator"
19
+ end
20
+
21
+ # This hook happens after all initializers are run, just before returning
22
+ config.after_initialize do
23
+ if defined?(::Noticed)
24
+ # Add `deliver_acidicly` to Noticed
25
+ ::Noticed::Base.include(Extensions::Noticed)
26
+ end
27
+ end
28
+ end
29
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module AcidicJob
4
- VERSION = "1.0.0.beta.2"
4
+ VERSION = "1.0.0.beta.3"
5
5
  end
data/lib/acidic_job.rb CHANGED
@@ -14,11 +14,11 @@ require_relative "acidic_job/workflow_step"
14
14
  require_relative "acidic_job/workflow"
15
15
  require_relative "acidic_job/processor"
16
16
  require_relative "acidic_job/perform_wrapper"
17
+ require_relative "acidic_job/extensions/action_mailer"
18
+ require_relative "acidic_job/extensions/noticed"
17
19
  require_relative "acidic_job/mixin"
18
20
  require_relative "acidic_job/base"
19
21
  require_relative "acidic_job/active_kiq"
20
- require_relative "acidic_job/extensions/action_mailer"
21
- require_relative "acidic_job/extensions/noticed"
22
22
 
23
23
  require_relative "acidic_job/serializers/exception_serializer"
24
24
  require_relative "acidic_job/serializers/finished_point_serializer"
@@ -28,6 +28,8 @@ require_relative "acidic_job/serializers/recovery_point_serializer"
28
28
  require_relative "acidic_job/serializers/worker_serializer"
29
29
  require "active_job/serializers"
30
30
 
31
+ require_relative "acidic_job/rails"
32
+
31
33
  module AcidicJob
32
34
  ::ActiveJob::Serializers.add_serializers(
33
35
  Serializers::ExceptionSerializer,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: acidic_job
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.beta.2
4
+ version: 1.0.0.beta.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - fractaledmind
@@ -261,6 +261,7 @@ files:
261
261
  - lib/acidic_job/mixin.rb
262
262
  - lib/acidic_job/perform_wrapper.rb
263
263
  - lib/acidic_job/processor.rb
264
+ - lib/acidic_job/rails.rb
264
265
  - lib/acidic_job/recovery_point.rb
265
266
  - lib/acidic_job/run.rb
266
267
  - lib/acidic_job/serializer.rb