sysvmq 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -1
- data/ext/sysvmq.c +2 -0
- data/sysvmq.gemspec +1 -1
- data/test/sysv_mq_test.rb +14 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dca403d32733e9e161c9e1f5a3fa31d2b5fce1c5
|
4
|
+
data.tar.gz: f2aa09248715a7e67f3276114fdaf1bd4ed3d10e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8b885eb6c8d5a988190542a421cc97df868d335dd90e36ebe1c377985c8c76024286d6d39f820d9620376d39a2a6f19b52cfd388f61ae4edcca324c751a2ac7d
|
7
|
+
data.tar.gz: e3e501ce8b8a98266c7f0bfa2c90f388f5e78dce1468e3dadf595d8fbe9336dd8dae4f8220b26be39e4f9c811eb536179190250a38ea400cab3c97db267fb40d
|
data/README.md
CHANGED
@@ -12,9 +12,12 @@ implemented on OS X, which POSIX MQs are not.
|
|
12
12
|
Note that `sysvmq` doesn't rely on any third-party message broker. The message
|
13
13
|
queue is handled by the kernel. It's extremely stable and performant.
|
14
14
|
|
15
|
+
`sysvmq` has been tested heavily in production at Shopify, under more than `100k
|
16
|
+
RPM`.
|
17
|
+
|
15
18
|
## Installation
|
16
19
|
|
17
|
-
Add `
|
20
|
+
Add `sysvmq` to your Gemfile.
|
18
21
|
|
19
22
|
`gem 'sysvmq'`
|
20
23
|
|
data/ext/sysvmq.c
CHANGED
@@ -282,6 +282,8 @@ sysvmq_send(int argc, VALUE *argv, VALUE self)
|
|
282
282
|
if (argc >= 2) priority = argv[1];
|
283
283
|
if (argc == 3) flags = argv[2];
|
284
284
|
|
285
|
+
message = rb_funcall(message, rb_intern("to_s"), 0);
|
286
|
+
|
285
287
|
TypedData_Get_Struct(self, sysvmq_t, &sysvmq_type, sysv);
|
286
288
|
|
287
289
|
Check_Type(flags, T_FIXNUM);
|
data/sysvmq.gemspec
CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = "sysvmq"
|
7
|
-
spec.version = '0.2.
|
7
|
+
spec.version = '0.2.2'
|
8
8
|
spec.authors = ["Simon Eskildsen"]
|
9
9
|
spec.email = ["sirup@sirupsen.com"]
|
10
10
|
spec.summary = %q{Ruby wrapper for SysV Message Queues}
|
data/test/sysv_mq_test.rb
CHANGED
@@ -130,4 +130,18 @@ class SysVMQTest < MiniTest::Unit::TestCase
|
|
130
130
|
@mq.send(message)
|
131
131
|
assert_equal message, @mq.receive
|
132
132
|
end
|
133
|
+
|
134
|
+
def test_number_converted_to_string
|
135
|
+
message = 1
|
136
|
+
@mq.send(message)
|
137
|
+
assert_equal "1", @mq.receive
|
138
|
+
end
|
139
|
+
|
140
|
+
class Walrus; def to_s; "walrus"; end; end
|
141
|
+
|
142
|
+
def test_object_converted_to_string
|
143
|
+
message = Walrus.new
|
144
|
+
@mq.send(message)
|
145
|
+
assert_equal "walrus", @mq.receive
|
146
|
+
end
|
133
147
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sysvmq
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Simon Eskildsen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-10-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -94,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
94
94
|
version: '0'
|
95
95
|
requirements: []
|
96
96
|
rubyforge_project:
|
97
|
-
rubygems_version: 2.2.
|
97
|
+
rubygems_version: 2.2.2
|
98
98
|
signing_key:
|
99
99
|
specification_version: 4
|
100
100
|
summary: Ruby wrapper for SysV Message Queues
|