Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Reuse amqp connection in mapper proxy if available.

  • Loading branch information...
commit 5a80056504ee282868b9ce5f4f89f24112a22cfd 1 parent 1136bca
@roidrage roidrage authored
Showing with 2 additions and 2 deletions.
  1. +1 −1  lib/nanite/agent.rb
  2. +1 −1  lib/nanite/mapper_proxy.rb
View
2  lib/nanite/agent.rb
@@ -243,7 +243,7 @@ def setup_heartbeat
end
def setup_mapper_proxy
- @mapper_proxy = MapperProxy.new(identity, options)
+ @mapper_proxy = MapperProxy.new(identity, options.merge(:amqp => @amqp))
end
def advertise_services
View
2  lib/nanite/mapper_proxy.rb
@@ -23,7 +23,7 @@ def initialize(id, opts)
@options = opts || {}
@identity = id
@pending_requests = {}
- @amqp = start_amqp(options)
+ @amqp = options[:amqp] || start_amqp(options)
@serializer = Serializer.new(options[:format])
@@instance = self
end
Please sign in to comment.
Something went wrong with that request. Please try again.