0
RabbitMQでセロリ(バージョン4.0.2)を使うことはできません。私は(セロリのtutorial/docで提案されているように)tasks.pyファイルに次のようしている:私は、次の奇妙なエラーが出ますRabbitMQでセロリを作るには
celery -A tasks worker --loglevel=info
:
from celery import Celery
app = Celery('tasks', broker='pyamqp://[email protected]//')
@app.task
def add(x, y):
return x + y
をしかし、私は、このコマンドを押すと、
Cannot connect to amqp://guest:**@127.0.0.1:5672//: [Errno 22] Invalid argument.
私のRabbitMQサーバーが実行されています。ここで私は「rabbitmqctl状態」コマンドを押したときに私が得るものです:
[{pid,188},
{running_applications,[{rabbit,"RabbitMQ","3.6.6"},
{os_mon,"CPO CXC 138 46","2.2.14"},
{rabbit_common,[],"3.6.6"},
{mnesia,"MNESIA CXC 138 12","4.11"},
{xmerl,"XML parser","1.3.5"},
{ranch,"Socket acceptor pool for TCP protocols.",
"1.2.1"},
{sasl,"SASL CXC 138 11","2.3.4"},
{stdlib,"ERTS CXC 138 10","1.19.4"},
{kernel,"ERTS CXC 138 10","2.16.4"}]},
{os,{unix,linux}},
{erlang_version,"Erlang R16B03 (erts-5.10.4) [source] [64-bit] [smp:4:4] [async-threads:64] [kernel-poll:true]\n"},
{memory,[{total,45625464},
{connection_readers,0},
{connection_writers,0},
{connection_channels,0},
{connection_other,0},
{queue_procs,2704},
{queue_slave_procs,0},
{plugins,0},
{other_proc,18736352},
{mnesia,60216},
{mgmt_db,0},
{msg_index,51568},
{other_ets,933528},
{binary,1069976},
{code,19343063},
{atom,711569},
{other_system,4716488}]},
{alarms,[]},
{listeners,[{clustering,25672,"::"},{amqp,5672,"::"}]},
{vm_memory_high_watermark,0.4},
{vm_memory_limit,6819561472},
{disk_free_limit,50000000},
{disk_free,188958461952},
{file_descriptors,[{total_limit,1948},
{total_used,2},
{sockets_limit,1751},
{sockets_used,0}]},
{processes,[{limit,1048576},{used,141}]},
{run_queue,0},
{uptime,1138},
{kernel,{net_ticktime,60}}]
また、私は、Python 2.7を使用しています。 誰かが問題になる可能性のあるアイデアはありますか?