sidekiq-sqs 0.0.10 → 0.0.11
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/sidekiq-sqs.rb +1 -2
- data/lib/sidekiq-sqs/util.rb +3 -11
- data/lib/sidekiq-sqs/version.rb +1 -1
- data/spec/util_spec.rb +3 -2
- metadata +1 -1
data/lib/sidekiq-sqs.rb
CHANGED
@@ -7,7 +7,6 @@ require 'sidekiq-sqs/fetcher'
|
|
7
7
|
require 'sidekiq-sqs/client'
|
8
8
|
require 'sidekiq-sqs/processor'
|
9
9
|
require 'sidekiq-sqs/worker'
|
10
|
-
require 'sidekiq-sqs/util'
|
11
10
|
require 'sidekiq-sqs/aws-sdk/batch_send_failure_patch'
|
12
11
|
|
13
12
|
# TODO The retry server middleware directly writes to a retry zset.
|
@@ -21,13 +20,13 @@ module Sidekiq
|
|
21
20
|
require 'sidekiq/fetch'
|
22
21
|
require 'sidekiq/client'
|
23
22
|
require 'sidekiq/processor'
|
23
|
+
require 'sidekiq-sqs/util'
|
24
24
|
|
25
25
|
Sidekiq::Manager.send :include, Sidekiq::Sqs::Manager
|
26
26
|
Sidekiq::Fetcher.send :include, Sidekiq::Sqs::Fetcher
|
27
27
|
Sidekiq::Client.send :include, Sidekiq::Sqs::Client
|
28
28
|
Sidekiq::Processor.send :include, Sidekiq::Sqs::Processor
|
29
29
|
Sidekiq::Worker::ClassMethods.send :include, Sidekiq::Sqs::Worker
|
30
|
-
Sidekiq::Util.send :include, Sidekiq::Sqs::Util
|
31
30
|
AWS::SQS::Queue.send :include, Sidekiq::Sqs::AwsSdk::BatchSendFailurePatch
|
32
31
|
|
33
32
|
# Can't figure how to include/extend and not get a private method...
|
data/lib/sidekiq-sqs/util.rb
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
module Sidekiq
|
2
|
-
module
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
included do
|
7
|
-
remove_method :constantize
|
8
|
-
end
|
9
|
-
|
10
|
-
def constantize(string)
|
11
|
-
string.constantize
|
12
|
-
end
|
2
|
+
module Util
|
3
|
+
def constantize(string)
|
4
|
+
string.constantize
|
13
5
|
end
|
14
6
|
end
|
15
7
|
end
|
data/lib/sidekiq-sqs/version.rb
CHANGED
data/spec/util_spec.rb
CHANGED
@@ -1,11 +1,12 @@
|
|
1
1
|
require 'spec_helper'
|
2
2
|
|
3
|
-
Sidekiq::Util.send :include, Sidekiq::Sqs::Util
|
4
3
|
class UtilTest
|
5
4
|
include Sidekiq::Util
|
6
5
|
end
|
7
6
|
|
8
|
-
|
7
|
+
require 'sidekiq-sqs/util'
|
8
|
+
|
9
|
+
describe Sidekiq::Util do
|
9
10
|
subject { UtilTest.new }
|
10
11
|
|
11
12
|
describe ".constantize" do
|