mirror of
https://github.com/WhaleFell/SMSBoom.git
synced 2026-02-03 02:15:10 +08:00
🐞 fix: celery server
celery server example
This commit is contained in:
9
celery_server/tasks.py
Normal file
9
celery_server/tasks.py
Normal file
@@ -0,0 +1,9 @@
|
||||
from .celery import app
|
||||
from .celery import logger
|
||||
import time
|
||||
|
||||
@app.task
|
||||
def test(x, y):
|
||||
logger.info("开始执行 test() 方法")
|
||||
time.sleep(5)
|
||||
logger.info("test() 方法执行成功")
|
||||
Reference in New Issue
Block a user