I need to start my google app engine project locally. It works normally on google server, but debugging becomes a pain, since deployment on each fix takes a lot of time. I've almost managed to start it locally, but I don't understand how to create queues, which are necessary. My steps:
run dev_appserver.py app.yaml
, following using local development server guide. All works fine except of queues:_, err := taskqueue.Add(u.Ctx(), task, queueName) exceptions.ThrowIfErr(true, "err_msg", err)
Throws
Panic! UserMessage: <err_msg>, Error: API error 1 (taskqueue: UNKNOWN_QUEUE),...
I can easily create queues on remote server (using creating push and creating pull guides):
gcloud app deploy queue.yaml
For
queue.yaml
:queue: - name: Pull-Data-Queue mode: pull - name: Push-Data-Queue mode: push rate: 1/s
- I can open http://localhost:8000/datastore and see some created data.
- I can open http://localhost:8000/taskqueue and see the only one default push queue. No tools to add new queues here.
Google guide says queues can't be created dynamically from code, only by yaml or xml. But how to create them in local environment. Is it even possible? gcloud app deploy queue.yaml
works only for remote deployment as far as I understand.
queue.yaml
file is side-by-side with yourapp.yaml
file the development server should detect it automatically (at least it does for python). If it's not in that place move it (or symlink it) there. – Dan Cornilescu