Tryton SQS异步执行模块帮助开发者使用Amazon SQS和工作线程来异步执行长时间运行和阻塞的任务。
快速开始
from trytond.modules.async_sqs import async_task
class MyBigReport(Report):
__name__ = 'report.bigreport'
@async_task()
def expensive_method(self, arg1, arg2):
\"\"\" An expensive method which determines your future \"\"\"
# do something hard and figure it out
return your_future
暂无评论