1
Amazon SQSで動作するようにしようとしていますが、タスクは実行されません。しかし、私の仕事は、彼らは非常に日付を記入しているように見えるアマゾンSQSをDjangoセロリと一緒に使うにはどうすればいいですか
https://www.caktusgroup.com/blog/2011/12/19/using-django-and-celery-amazon-sqs/
ここで私は(特に)しようとしているリンクがある
RabbitMQの
で箱から出して実行します。私はアマゾンコンソールにログインしますが、私は見セロリのログは、彼らは私の設定はBROKER_TRANSPORT = 'sqs'
BROKER_TRANSPORT_OPTIONS = {
'region': 'eu-west-1',
'polling_interval': 2,
'visibility_timeout': 3600,
}
BROKER_USER = 'xxx'
BROKER_PASSWORD = 'xxxxx/xxxx'
CELERY_IMPORTS = (
'apps.files.tasks',
)
CELERY_QUEUES = {
'default': {
'binding_key': 'default'
},
# Files
'files_copy_paste': {
'binding_key': 'files.copy.paste'
},
}
すべてのヘルプですアマゾン
DEBUG b'<?xml version="1.0"?><ReceiveMessageResponse xmlns="http://queue.amazonaws.com/doc/2012-11-05/"><ReceiveMessageResult/><ResponseMetadata><RequestId>f8d10c14-99f7-520b-a58d-5d2cc203ad8b</RequestId></ResponseMetadata></ReceiveMessageResponse>'
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Method: GET
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Path: /967610578225/transfer_files
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Data:
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Headers: {}
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Host: eu-west-1.queue.amazonaws.com
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Port: 443
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Params: {'Version': '2012-11-05', 'Action': 'ReceiveMessage', 'WaitTimeSeconds': 0, 'MaxNumberOfMessages': 4}
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG Token: None
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log DEBUG CanonicalRequest:
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log GET
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log /967610578225/transfer_files
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log Action=ReceiveMessage&MaxNumberOfMessages=4&Version=2012-11-05&WaitTimeSeconds=0
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log host:eu-west-1.queue.amazonaws.com
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log x-amz-date:20170307T065652Z
Mar 7 08:56:52 ip-172-31-41-253 e-celery-worker.log
, 'Authorization': 'AWS4-HMAC-SHA256 Credential=xxxxxx/20170307/eu-west-1/sqs/aws4_request,SignedHeaders=host;x-amz-date,Signature=xxxxxx', 'User-Agent': 'Boto/2.45.0 Python/3.4.3 Linux/4.1.17-22.30.amzn1.x86_64', 'X-Amz-Date': '20170307T065652Z'}
Mar 7 08:56:52 ip-172-31-41-253 eright-celery-worker.log DEBUG Response headers: [('Server', 'Server'), ('Date', 'Tue, 07 Mar 2017 06:56:52 GMT'), ('Content-Type', 'text/xml'), ('Content-Length', '240'), ('Connection', 'keep-alive'), ('x-amzn-RequestId', 'bbad9a79-f65e-568d-aaeb-cb41adaa390d')]
と通信している示す活性を有しているとき、私の合図に私はすべてのメッセージは受信されません。途方もなく私はジャンゴ+セロリは、以下の設定でSQSで作業してい
こんにちは@Isaac、問題はAWS_ACCESS_KEY_IDとAWS_SECRET_ACCESS_KEYがS3用に設定されているため、s3ユーザーのアクセスを使用する必要があります。ブローカーのために私はasumed BROKER_USER = 'xxx' BROKER_PASSWORD = 'xxxxx/xxxx'は私のアクセスキーとIDを入れます。地域の正面にsqsを置くあなたのポイントは、私が試していない唯一のものです、私はそれを正しく取得し、それが動作するかどうかをお知らせします –
@TawandaMinyaねえ、それは動作しましたか? :)もしそうなら、私の答えを受け入れてください。 –
こんにちは、まだテストする機会はありませんでした。しかし、私がするときに –