coney_island 0.7 → 0.7.1

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: 7c6e16e85747e1d7eb7ca008b0b193d0b7bb5968
4
- data.tar.gz: 26c71402914d4a3947270aed653da903955ce0b2
3
+ metadata.gz: 7d3235b3a4ba3ab30ab945fe646f984e590fadc3
4
+ data.tar.gz: 0c246415fb168c1bfa4f7164c9d351cd1fa71a75
5
5
  SHA512:
6
- metadata.gz: 8798aa23ab52a69563f618cbe330279389635a6abe0432b95a599913610cf05a701387fa6142467bf4b5b9f6497f8c3e3bba40b7fbef08f5650a09f5b9cf8502
7
- data.tar.gz: e76ed3ee358c56c542fc4ce909aed4e0fc0f849bdb6eaccd5044b11d987c619f01f35446014f0b1c02c10243191894c174985a35dc917ca860475f4bd85bb94f
6
+ metadata.gz: bdff43883e7dad6eed7488bef99997eecd2c4414518790bfe8c0db483ad4e5a489fada58167e07d7155a28501cf75e10ef8ae05dea5e013c698d3cb147281049
7
+ data.tar.gz: c3afba951a9fc3eeedf21a6239421db1c88847f934572720fef74391fe01b4dcc63a6e2249df9ea6fdbc92df8f76cc426d232eb19015eabd4905b4dc58c8c59e
@@ -1,3 +1,3 @@
1
1
  module ConeyIsland
2
- VERSION = "0.7"
2
+ VERSION = "0.7.1"
3
3
  end
@@ -78,16 +78,16 @@ module ConeyIsland
78
78
  defined?(ActiveRecord::Base) and
79
79
  ActiveRecord::Base.establish_connection
80
80
 
81
- EventMachine.run do
81
+ begin
82
+ EventMachine.run do
82
83
 
83
- Signal.trap('INT') do
84
- self.shutdown('INT')
85
- end
86
- Signal.trap('TERM') do
87
- self.shutdown('TERM')
88
- end
84
+ Signal.trap('INT') do
85
+ self.shutdown('INT')
86
+ end
87
+ Signal.trap('TERM') do
88
+ self.shutdown('TERM')
89
+ end
89
90
 
90
- begin
91
91
  AMQP.connect(self.amqp_parameters) do |connection|
92
92
  self.log.info("Connected to AMQP broker. Running #{AMQP::VERSION}")
93
93
  @channel = AMQP::Channel.new(connection)
@@ -106,22 +106,22 @@ module ConeyIsland
106
106
  self.handle_incoming_message(metadata,payload)
107
107
  end
108
108
  end
109
- rescue AMQP::TCPConnectionFailed => e
110
- ConeyIsland.tcp_connection_retries ||= 0
111
- ConeyIsland.tcp_connection_retries += 1
112
- if ConeyIsland.tcp_connection_retries >= ConeyIsland.tcp_connection_retry_limit
113
- message = "Failed to connect to RabbitMQ #{ConeyIsland.tcp_connection_retry_limit} times, bailing out"
114
- self.log.error(message)
115
- ConeyIsland.poke_the_badger(e, {
116
- code_source: 'ConeyIsland::Worker.start',
117
- reason: message}
118
- )
119
- else
120
- message = "Failed to connecto to RabbitMQ Attempt ##{ConeyIsland.tcp_connection_retries} time(s), trying again in #{ConeyIsland.tcp_connection_retry_interval} seconds..."
121
- self.log.error(message)
122
- sleep(10)
123
- retry
124
- end
109
+ end
110
+ rescue AMQP::TCPConnectionFailed => e
111
+ ConeyIsland.tcp_connection_retries ||= 0
112
+ ConeyIsland.tcp_connection_retries += 1
113
+ if ConeyIsland.tcp_connection_retries >= ConeyIsland.tcp_connection_retry_limit
114
+ message = "Failed to connect to RabbitMQ #{ConeyIsland.tcp_connection_retry_limit} times, bailing out"
115
+ self.log.error(message)
116
+ ConeyIsland.poke_the_badger(e, {
117
+ code_source: 'ConeyIsland::Worker.start',
118
+ reason: message}
119
+ )
120
+ else
121
+ message = "Failed to connecto to RabbitMQ Attempt ##{ConeyIsland.tcp_connection_retries} time(s), trying again in #{ConeyIsland.tcp_connection_retry_interval} seconds..."
122
+ self.log.error(message)
123
+ sleep(10)
124
+ retry
125
125
  end
126
126
  end
127
127
  end
@@ -2,3 +2,5 @@ ConeyIsland::Submitter.submit! about to iterate over this many jobs: 1
2
2
  Failed to connecto to RabbitMQ Attempt #1 time(s), trying again in 0 seconds...
3
3
  ConeyIsland::Submitter.submit! about to iterate over this many jobs: 1
4
4
  Failed to connecto to RabbitMQ Attempt #1 time(s), trying again in 0 seconds...
5
+ ConeyIsland::Submitter.submit! about to iterate over this many jobs: 1
6
+ Failed to connecto to RabbitMQ Attempt #1 time(s), trying again in 0 seconds...
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: coney_island
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.7'
4
+ version: 0.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Draut
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-01-26 00:00:00.000000000 Z
12
+ date: 2015-01-27 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails