basicjrpc 0.1.61 → 0.1.62
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/basicjrpc/server.rb +4 -2
- data/lib/basicjrpc/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6a2c026f7b8f0043bcc1b38d211fc13fdff7b45a
|
4
|
+
data.tar.gz: e3d406307b927ae8b1444acf0f0014335b6540e7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 66706840ac79d86211e4b988071b2dbb64e8eaaba2fb063ac09024b179939e4bbed6c42ed49fffe525d8af8aef9b00193a61d86703b5dd2d60dc7146adac0922
|
7
|
+
data.tar.gz: 1292313cff74bd5ddb3b92d6d60c99f0c362bfe7e635881c309e92e3ee17c3681b66b03714913ae987d89a132c7dff7bc641c4615b032820f0230ee0ca499f37
|
data/lib/basicjrpc/server.rb
CHANGED
@@ -5,16 +5,18 @@ module BasicJRPC
|
|
5
5
|
@injected_class = injected_class
|
6
6
|
@queue = queue
|
7
7
|
#@nsq_consumer = Nsq::Consumer.new(nsqlookupd: 'dockerlb:4161', topic: @queue, channel: 'server')
|
8
|
-
@
|
8
|
+
@host = host
|
9
9
|
end
|
10
10
|
|
11
11
|
def listen
|
12
12
|
puts "Listening..."
|
13
|
+
@redis = Redis.new(host: host)
|
14
|
+
|
13
15
|
while true
|
14
16
|
begin
|
15
17
|
redis_response = @redis.brpop(@queue)
|
16
18
|
rescue
|
17
|
-
@redis = Redis.new(host: host)
|
19
|
+
@redis = Redis.new(host: @host)
|
18
20
|
puts "REDIS FAILED! RETRYING"
|
19
21
|
retry
|
20
22
|
end
|
data/lib/basicjrpc/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: basicjrpc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.62
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Martin Simpson
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-01-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|