Class: SimpleMessageQueue::Notification

Inherits:
Object
  • Object
show all
Defined in:
lib/simple_message_queue/notification.rb

Defined Under Namespace

Classes: Topic

Class Method Summary collapse

Class Method Details

.snsObject



6
7
8
9
10
# File 'lib/simple_message_queue/notification.rb', line 6

def sns
  raise SimpleMessageQueue::ConfigurationError unless SimpleMessageQueue.configuration
  raise SimpleMessageQueue::EnvironmentError unless defined?(SimpleMessageQueue.configuration.environment)
  @@sns ||= AWS::SNS.new(:access_key_id => SimpleMessageQueue.configuration.access_key_id, :secret_access_key => SimpleMessageQueue.configuration.secret_access_key)
end