alephant-harness 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/alephant/harness/service/sqs.rb +8 -4
- data/lib/alephant/harness/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 293fb770e23d71cd2b802ebc255924460d8caf55
|
4
|
+
data.tar.gz: 85dce6c32c89b470cdbecd5979b4bd7f61b62813
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 77f0dd79319c7cd62e8f70c2cd2fd335c732906901fe9999f8e35a5fae790d13c99d976f4d5fec45f265f4de5023ece9135a01bdd5e7aa1a4a3fa20b7f158e4d
|
7
|
+
data.tar.gz: ad20cdd2bc1ee8d8d6eed94a7d063f9646c64340bf8b25b62be529ae0d6c598a55a4aefa325bdf8c6a0dad234c32831798499857f50e61267c90b79ae82080c6
|
@@ -10,11 +10,11 @@ module Alephant
|
|
10
10
|
end
|
11
11
|
|
12
12
|
def self.create(queue)
|
13
|
-
client.queues.create
|
13
|
+
client.queues.create queue_name(queue)
|
14
14
|
end
|
15
15
|
|
16
|
-
def self.get(
|
17
|
-
client.queues.named(queue_name)
|
16
|
+
def self.get(queue)
|
17
|
+
client.queues.named(queue_name(queue))
|
18
18
|
rescue ::AWS::SQS::Errors::NonExistentQueue
|
19
19
|
false
|
20
20
|
end
|
@@ -26,7 +26,11 @@ module Alephant
|
|
26
26
|
end
|
27
27
|
|
28
28
|
def self.delete(queue_name)
|
29
|
-
|
29
|
+
get(queue_name).delete
|
30
|
+
end
|
31
|
+
|
32
|
+
def self.queue_name(queue)
|
33
|
+
/(?<name>[^\/]+)$/.match(queue)[:name]
|
30
34
|
end
|
31
35
|
|
32
36
|
end
|