Method: RightAws::SqsInterface#add_grant
- Defined in:
- lib/sqs/right_sqs_interface.rb
#add_grant(queue_url, grantee_email_address, permission = nil) ⇒ Object
Adds grants for user (identified by email he registered at Amazon). Returns true
or an exception. Permission = ‘FULLCONTROL’ | ‘RECEIVEMESSAGE’ | ‘SENDMESSAGE’.
sqs.add_grant('http://queue.amazonaws.com/ZZ7XXXYYYBINS/my_awesome_queue', '[email protected]', 'FULLCONTROL') #=> true
237 238 239 240 241 242 243 244 245 |
# File 'lib/sqs/right_sqs_interface.rb', line 237 def add_grant(queue_url, grantee_email_address, = nil) req_hash = generate_request('AddGrant', 'Grantee.EmailAddress' => grantee_email_address, 'Permission' => , :queue_url => queue_url) request_info(req_hash, SqsStatusParser.new(:logger => @logger)) rescue on_exception end |