google app engine task queue sample

陌路散爱 提交于 2019-12-13 00:34:27

问题


Currently, i try to working with task queue. But i don't see any complete sample on this matter.

So please give me some sample of task queue in google app engine, written in python.


回答1:


import:

from google.appengine.api import taskqueue

define and run:

taskqueue.add(url='/service', params={'user': user}, method="GET")

url is the RequestHandler that leads to the code to run in the queue

params can be regular url params




回答2:


The example in Google's documentation is simple but complete. http://code.google.com/appengine/docs/python/taskqueue/overview.html



来源:https://stackoverflow.com/questions/5800885/google-app-engine-task-queue-sample

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!