march_hare 2.2.0-java → 2.3.0-java
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ext/rabbitmq-client.jar +0 -0
- data/lib/march_hare/session.rb +24 -0
- data/lib/march_hare/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: a62cd6766c3f98048cf58bfbf303b2702c801678
|
4
|
+
data.tar.gz: d02cccd64d98ee45a4ed842cb02873d508b3c1a9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 109d827d6592930e2f5490f0994f0560f1edcc84fec94ceb9479b10a884a5f9afd263fd53f17a23c28e099ec855385e189b788c2c7769f146cea0d36a4084bbe
|
7
|
+
data.tar.gz: 61196e97a7901247c01419b5bd77f36bf0a6c25d5babcea3ad213fd53be4702f8fb76990c9420fc25a709b1a13ff46f2b86d6d1eb81f4088bf67959f23ed8bb4
|
data/lib/ext/rabbitmq-client.jar
CHANGED
Binary file
|
data/lib/march_hare/session.rb
CHANGED
@@ -37,6 +37,7 @@ module MarchHare
|
|
37
37
|
# @option options [String] :vhost ("/") Virtual host to use
|
38
38
|
# @option options [Integer] :heartbeat (600) Heartbeat interval. 0 means no heartbeat.
|
39
39
|
# @option options [Boolean] :tls (false) Set to true to use TLS/SSL connection. This will switch port to 5671 by default.
|
40
|
+
# @option options [java.util.concurrent.ThreadFactory] :thread_factory Thread factory RabbitMQ Java client will use (useful in restricted PaaS platforms such as GAE)
|
40
41
|
#
|
41
42
|
# @see http://rubymarchhare.info/articles/connecting.html Connecting to RabbitMQ guide
|
42
43
|
def self.connect(options={})
|
@@ -53,6 +54,9 @@ module MarchHare
|
|
53
54
|
cf.requested_heartbeat = heartbeat_from(options) if include_heartbeat?(options)
|
54
55
|
cf.connection_timeout = connection_timeout_from(options) if include_connection_timeout?(options)
|
55
56
|
|
57
|
+
cf.thread_factory = thread_factory_from(options) if include_thread_factory?(options)
|
58
|
+
cf.exception_handler = exception_handler_from(options) if include_exception_handler?(options)
|
59
|
+
|
56
60
|
tls = (options[:ssl] || options[:tls])
|
57
61
|
case tls
|
58
62
|
when true then
|
@@ -348,6 +352,26 @@ module MarchHare
|
|
348
352
|
!!(options[:connection_timeout_interval] || options[:connection_timeout])
|
349
353
|
end
|
350
354
|
|
355
|
+
# @private
|
356
|
+
def self.thread_factory_from(opts)
|
357
|
+
opts[:thread_factory]
|
358
|
+
end
|
359
|
+
|
360
|
+
# @private
|
361
|
+
def self.include_thread_factory?(opts)
|
362
|
+
!!opts[:thread_factory]
|
363
|
+
end
|
364
|
+
|
365
|
+
# @private
|
366
|
+
def self.exception_handler_from(opts)
|
367
|
+
opts[:exception_handler]
|
368
|
+
end
|
369
|
+
|
370
|
+
# @private
|
371
|
+
def self.include_exception_handler?(opts)
|
372
|
+
!!opts[:exception_handler]
|
373
|
+
end
|
374
|
+
|
351
375
|
# Executes a block, catching Java exceptions RabbitMQ Java client throws and
|
352
376
|
# transforms them to Ruby exceptions that are then re-raised.
|
353
377
|
#
|
data/lib/march_hare/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: march_hare
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.3.0
|
5
5
|
platform: java
|
6
6
|
authors:
|
7
7
|
- Theo Hultberg
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-
|
12
|
+
date: 2014-06-30 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: RabbitMQ client for JRuby built around the official RabbitMQ Java client
|
15
15
|
email:
|