Skip to content

A simple wrapper for boto3 for receive, and sending, to an AWS SQS queue

License

Notifications You must be signed in to change notification settings

jeromewe/django-sqs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
温海杰
Apr 8, 2020
d7700ee · Apr 8, 2020

History

11 Commits
Apr 8, 2020
Apr 1, 2020
Apr 1, 2020
Apr 2, 2020
Apr 8, 2020
Apr 2, 2020

Repository files navigation

django-sqs-mq

概括

Supported Django and Python versions

Django \ Python 3.4 3.5 3.6 3.7 3.8
1.11 * * * * *
2.0 * * * * *

Documentation

Installation

To install django-sqs-mq:

$ pip install django-sqs-mq

Usage

Integrating django-sqs-mq support into your app is a three-step process:

  1. create your notice types
  2. create your notice templates
  3. send notifications

Creating Notice Types

You need to call NoticeType once to create the notice types for your application in the database.

  • label is the internal shortname that will be used for the type
  • display is what the user sees as the name of the notification type
  • description is a short description

For example:

import json
from django_sqs.launcher import SqsLauncher

kwargs = {

}
kwargs.update({'logs_type': 'operate_logs'})

SqsLauncher().send_message(json.dumps(**kwargs, ensure_ascii=False))

Contribute

Code of Conduct

License

Copyright (c) 2018-2020 MIT license.

About

A simple wrapper for boto3 for receive, and sending, to an AWS SQS queue

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages