Commit f4658bc7 authored by 吴升宇's avatar 吴升宇

fix retry

parent 867b198e
crontab: crontab:
cp crontab.py /data/log/physical/app/crontab.py && python /data/log/physical/app/crontab.py && python /data/log/physical/app/crontabs.py cp crontab.py /data/log/physical/app/crontab.py && python /data/log/physical/app/crontab.py && python /data/log/physical/app/crontabs.py
celery: celery:
celery -A physical worker -c 1 -Q vest -l debug celery -A physical worker -c 1 -Q tapir-alpha -l debug --max-tasks-per-child == 500
...@@ -114,7 +114,7 @@ def logins(user_id): ...@@ -114,7 +114,7 @@ def logins(user_id):
return None return None
@shared_task @shared_task(retry_kwargs={'max_retries': 0})
def click(cookies_get, id): def click(cookies_get, id):
# 点赞 # 点赞
try: try:
...@@ -148,7 +148,7 @@ def click(cookies_get, id): ...@@ -148,7 +148,7 @@ def click(cookies_get, id):
logging.error("catch exception,logins:%s" % traceback.format_exc()) logging.error("catch exception,logins:%s" % traceback.format_exc())
@shared_task @shared_task(retry_kwargs={'max_retries': 0})
def reply(cookies_get, id, content): def reply(cookies_get, id, content):
try: try:
post_dict = { post_dict = {
...@@ -272,7 +272,7 @@ def get_comments(): ...@@ -272,7 +272,7 @@ def get_comments():
return None return None
@shared_task @shared_task(retry_kwargs={'max_retries': 0})
def follow(cookies_get, id): def follow(cookies_get, id):
try: try:
post_dict = { post_dict = {
...@@ -438,7 +438,7 @@ def set_reply_to_redis(): ...@@ -438,7 +438,7 @@ def set_reply_to_redis():
logging.error("catch exception,logins:%s" % traceback.format_exc()) logging.error("catch exception,logins:%s" % traceback.format_exc())
@shared_task @shared_task(retry_kwargs={'max_retries': 0})
def reply2(cookies_get, id, content, replied_id): def reply2(cookies_get, id, content, replied_id):
try: try:
post_dict = { post_dict = {
...@@ -459,7 +459,7 @@ def reply2(cookies_get, id, content, replied_id): ...@@ -459,7 +459,7 @@ def reply2(cookies_get, id, content, replied_id):
logging.error("catch exception,logins:%s" % traceback.format_exc()) logging.error("catch exception,logins:%s" % traceback.format_exc())
@shared_task @shared_task(retry_kwargs={'max_retries': 0})
def pictorial_reply(cookies_get, id, content): def pictorial_reply(cookies_get, id, content):
try: try:
post_dict = { post_dict = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment