startback 0.9.0 → 0.9.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/startback/bus/bunny/async.rb +8 -2
- data/lib/startback/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c2a20858c9d0287af3cfaa8e60c6f59630f1d258de469f7c50ffe1e6529742ca
|
4
|
+
data.tar.gz: c5d3fb83ab9a7aa0b1bb6fbec2f0bfeef40b4c51c15c602d9a2bca85b17e8d26
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ee763fb9d8be8ca1f6cc8a541b70df6b72ae982e2026b04286ec5b6a208aba31641ea8062330f7efc8d01e548bfbca408edb115678dbc6fefa707e3d98fc8f0e
|
7
|
+
data.tar.gz: ec3607dec57ff640d4b49afb147a5c6893e45844e5d53cf07e8ca26ea709341260c02f01a25bad7fc68f231e859986ce2bb0604de7e6031f59f97d1f0a06a464
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.9.
|
1
|
+
0.9.1
|
@@ -35,6 +35,8 @@ module Startback
|
|
35
35
|
class Async
|
36
36
|
include Support::Robustness
|
37
37
|
|
38
|
+
CHANNEL_KEY = 'Startback::Bus::Bunny::Async::ChannelKey'
|
39
|
+
|
38
40
|
DEFAULT_OPTIONS = {
|
39
41
|
# (optional) The URL to use for connecting to RabbitMQ.
|
40
42
|
url: ENV['STARTBACK_BUS_BUNNY_ASYNC_URL'],
|
@@ -65,11 +67,15 @@ module Startback
|
|
65
67
|
try_max_times(10) do
|
66
68
|
@bunny = ::Bunny.new(conn)
|
67
69
|
@bunny.start
|
68
|
-
|
70
|
+
channel
|
69
71
|
log(:info, {op: "#{self.class.name}#connect", op_data: conn}, options[:context])
|
70
72
|
end
|
71
73
|
end
|
72
|
-
attr_reader :
|
74
|
+
attr_reader :options
|
75
|
+
|
76
|
+
def channel
|
77
|
+
Thread.current[CHANNEL_KEY] ||= @bunny.create_channel
|
78
|
+
end
|
73
79
|
|
74
80
|
def emit(event)
|
75
81
|
stop_errors(self, "emit", event.context) do
|
data/lib/startback/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: startback
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bernard Lambeau
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-12-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -470,7 +470,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
470
470
|
- !ruby/object:Gem::Version
|
471
471
|
version: '0'
|
472
472
|
requirements: []
|
473
|
-
rubygems_version: 3.2.
|
473
|
+
rubygems_version: 3.2.32
|
474
474
|
signing_key:
|
475
475
|
specification_version: 4
|
476
476
|
summary: Got Your Ruby Back
|