eventhub-processor 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/eventhub/processor.rb +4 -4
- data/lib/eventhub/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6e482fa2310d3abf811abc2862d0d9443a49c035
|
4
|
+
data.tar.gz: 2709b529e3d1fd38e99903a0c90784dab1614bf0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d6394811bbaa3287d44789de863815ec39d52e5c4a5b3d3cb27eaf4c4f7930a29c7d91dc0af369569b0c2679109ce011fea184a5c9d996afcbb1f5157c90831f
|
7
|
+
data.tar.gz: 6eddcf29b7fc924bbe6c57a572c12c2bd7b1f3cb90a01055333c1d3a2c2d4b4fbc85c0c8592d273557c7efaf2a1ca54e70e7b8b2296d15d4cf71ce841477f8e8
|
data/lib/eventhub/processor.rb
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
module EventHub
|
2
2
|
class Processor
|
3
3
|
|
4
|
-
def
|
5
|
-
configuration.get('server.
|
4
|
+
def host
|
5
|
+
configuration.get('server.host') || 'localhost'
|
6
6
|
end
|
7
7
|
|
8
8
|
def user
|
@@ -102,7 +102,7 @@ module EventHub
|
|
102
102
|
|
103
103
|
def watchdog
|
104
104
|
begin
|
105
|
-
response = RestClient.get "http://#{self.user}:#{self.password}@#{
|
105
|
+
response = RestClient.get "http://#{self.user}:#{self.password}@#{host}:#{management_port}/api/queues/#{self.vhost}/#{self.queue_name}/bindings", { :content_type => :json}
|
106
106
|
data = JSON.parse(response.body)
|
107
107
|
|
108
108
|
if response.code != 200
|
@@ -130,7 +130,7 @@ module EventHub
|
|
130
130
|
def send_to_dispatcher(payload)
|
131
131
|
confirmed = true
|
132
132
|
|
133
|
-
connection = Bunny.new({hostname: self.
|
133
|
+
connection = Bunny.new({hostname: self.host, user: self.user, password: self.password, vhost: "event_hub"})
|
134
134
|
connection.start
|
135
135
|
|
136
136
|
channel = connection.create_channel
|
data/lib/eventhub/version.rb
CHANGED