rabbitmq_client 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rabbitmq_client.rb +3 -1
- data/lib/rabbitmq_client/publisher.rb +2 -1
- data/lib/rabbitmq_client/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d2d9a57e2ad5856c1af410391b86ce13159d2f658902080ebfd65779576a874e
|
4
|
+
data.tar.gz: 501753ad4dd0fa15552e50e8c2a9e045e46f9dfe4333f497dff2970f6b5d4d88
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0f4e1d1de72f482ec925b429e809e0df7e541f1164209470ae664246785d14fc6c0e29ac412d688c409cc989a0dbce467640a63e9d6762d2e0ab156def74e09b
|
7
|
+
data.tar.gz: 9a4d74840356a92646dbdd1b5aed0893f6035245e45339cbbe1b685c544952adae1aebad900561945b9282c062967c41de6ab4289231eb6204badb47d0763503
|
data/lib/rabbitmq_client.rb
CHANGED
@@ -50,11 +50,13 @@ module RabbitmqClient
|
|
50
50
|
# default rabbitmq configs
|
51
51
|
# heartbeat_publisher = 0
|
52
52
|
# session_pool = 1
|
53
|
+
# session_pool_timeout = 5
|
53
54
|
config_accessor(:session_params, instance_accessor: false) do
|
54
55
|
{
|
55
56
|
heartbeat_publisher: 0,
|
56
57
|
async_publisher: true,
|
57
|
-
session_pool: 1
|
58
|
+
session_pool: 1,
|
59
|
+
session_pool_timeout: 5
|
58
60
|
}
|
59
61
|
end
|
60
62
|
|
@@ -57,7 +57,8 @@ module RabbitmqClient
|
|
57
57
|
|
58
58
|
def create_connection_pool
|
59
59
|
pool_size = @session_params.fetch(:session_pool, 1)
|
60
|
-
|
60
|
+
pool_timeout = @session_params.fetch(:session_pool_timeout, 5)
|
61
|
+
ConnectionPool.new(size: pool_size, timeout: pool_timeout) do
|
61
62
|
Bunny.new(@config[:rabbitmq_url],
|
62
63
|
{ logger: RabbitmqClient.logger }.merge(@session_params))
|
63
64
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rabbitmq_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Al-waleed shihadeh
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-01-
|
11
|
+
date: 2020-01-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|