lapine 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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b4ad8bb1d60dc16d7f9531b492176332c3dac14e
4
- data.tar.gz: c049aa2584874e2bbc1c5ed3002ec031015b1d37
3
+ metadata.gz: f7e95ed028d5cbadaf4b7fdd8ad5e23999e90abe
4
+ data.tar.gz: 94963d6e447234a9f769fb5777e0a2dd123ff474
5
5
  SHA512:
6
- metadata.gz: 9c2d60646a969b2b9a22fd88bac14fbc223912046aaccb4a2bcafa4504e2140b702dae9dd8c2ea20c194d0a8251ef7c979b3faba12d8f7ae332881bdfc7d762b
7
- data.tar.gz: a58da4934ad1efcf307065b906f362a75878a37ec2b40fa9f9df2496afd081679c9c055ef7be6a17f3e110c9c2dcc1c5769bcc0d20358291e6558f79abe8d6f8
6
+ metadata.gz: 2e69fdf1807c1fd4b22086daf824762c85941b95083c3c05ccbd733a6cf3ed6c73a3ea0da9abac202d1e921d2461752a467ebfab3483dd5c61b5afa8d552149d
7
+ data.tar.gz: ed3c4fdd7cf66dbc480c2e6c530bda3e12f852ece1ffedca48f75c7a68ff63105511e25f0d555803e3c8a0d3bf42dc0d543d7252c9bc153717bbf097275497ea
@@ -2,11 +2,13 @@ require 'bunny'
2
2
 
3
3
  module Lapine
4
4
  class Connection
5
- attr_reader :conn, :name, :props
5
+ attr_reader :conn, :name, :props, :connection_name, :exchange_type
6
6
 
7
7
  def initialize(name, properties)
8
8
  @name = name
9
9
  @props = properties.dup
10
+ @connection_name = props.delete(:connection)
11
+ @exchange_type = props.delete(:type)
10
12
  end
11
13
 
12
14
  def exchange
@@ -15,11 +17,10 @@ module Lapine
15
17
  end
16
18
 
17
19
  def reconnect
18
- connection_props = Lapine.config.connection_properties[props.delete(:connection)]
20
+ connection_props = Lapine.config.connection_properties[connection_name]
19
21
  @conn = Bunny.new(connection_props)
20
22
  conn.start
21
23
  channel = conn.create_channel
22
- exchange_type = props.delete(:type)
23
24
  @exchange = Bunny::Exchange.new(channel, exchange_type, name, props)
24
25
  end
25
26
  end
@@ -1,3 +1,3 @@
1
1
  module Lapine
2
- VERSION = '0.0.2'
2
+ VERSION = '0.0.3'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lapine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Saxby
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-11-06 00:00:00.000000000 Z
12
+ date: 2014-11-10 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bunny