messaging_client 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/messaging/client.rb +5 -1
- metadata +1 -2
- data/config/initializers/aws_sdk.rb +0 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a4b03ed1272c559e375e6db2d3bf73baec70798f
|
4
|
+
data.tar.gz: 96109976ad4ea33eeeb42a33a2b9510d60ac6be9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2676f5ee361657958573f74b7fc028fef6985c6381f90c646fc767d4b08ceee221f58441515df2119e29f499521f4aa2175e8d679061bf13687c7008fc246143
|
7
|
+
data.tar.gz: dde9b5d7ad4551b4ee572749c21c06a2fff7c6142ae8c0140877a1449d2377e9bae79a6e0f902a7b8de354f10ee1582ccceb01d92cdc781f746857d3d3119b7f
|
data/lib/messaging/client.rb
CHANGED
@@ -25,7 +25,11 @@ module Messaging
|
|
25
25
|
end
|
26
26
|
|
27
27
|
def self.publish_to_sns(key,data)
|
28
|
-
sns = Aws::SNS::Resource.new(
|
28
|
+
sns = Aws::SNS::Resource.new(
|
29
|
+
region: 'us-east-1',
|
30
|
+
access_key_id: SNS_KEY_ID,
|
31
|
+
secret_access_key: SNS_SECRET_ACCESS_KEY
|
32
|
+
)
|
29
33
|
topic_arn = sns.topics.select{|t| t.arn.match(/([^:]*)$/)[0] == key.to_s }.first
|
30
34
|
topic = sns.topic(topic_arn)
|
31
35
|
topic.publish({ message: data.to_json })
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: messaging_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dwayne Macgowan
|
@@ -61,7 +61,6 @@ extra_rdoc_files: []
|
|
61
61
|
files:
|
62
62
|
- app/models/messaging/message.rb
|
63
63
|
- app/models/messaging/notify_me.rb
|
64
|
-
- config/initializers/aws_sdk.rb
|
65
64
|
- config/initializers/messaging_client.rb
|
66
65
|
- lib/messaging/client.rb
|
67
66
|
- lib/messaging/railties.rb
|