You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
qoo is a very simple Amazon SQS client, written in Python. It aims
to be much more straight-forward to use than boto3, and specializes only
in Amazon SQS, ignoring the rest of the AWS ecosystem.
Features
Easier interaction with SQS queues
Automatic support for AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY,
and AWS_DEFAULT_REGION environment variables.
automatic useful message/job metadata
Usage
Installation
pip install qoo
Basic Usage
importqoo# list SQS queue namesqoo.list_queues()
# get an existing queuequeue=qoo.get("$QUEUE_NAME")
# or create a queuequeue=qoo.create("$QUEUE_NAME")
# send a job, pass info/keys as kwargsqueue.send(info="foo", user_id="test_user") # etc.# get an approximate count of messages in the queuelen(queue) # approximate total messagesqueue.approx_not_visible# approximate number of message in the visibility timeout# get a jobjob=queue.receive(wait_time=1)
job.elapsed# time between sending the job and receiving itjob.md5_matches# boolean property to show that the md5 of the job matches what was sent# and the data from the job is automatically converted into attrsjob.info# the string "foo"job.user_id# the string "test_user"# delete the job from the SQS queuejob.delete()