每次项目运行时,应用引擎数据存储区都将自动清除 [英] app engine datastore auto-clears every time project runs

查看:153
本文介绍了每次项目运行时,应用引擎数据存储区都将自动清除的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

每次运行我的项目(ej dev_appserver.py myapp或manage.py runserver在django中)时,数据存储将被清除。我已经在django中使用model.put()或model.save()来保存数据。在当前会话中,我可以看到管理页面中的数据,但下次运行该项目时,所有以前的数据存储区都将丢失。

Every time I run my project (eith dev_appserver.py myapp or manage.py runserver in django), the datastore will be cleared. I have persisted the data by model.put() or model.save() in django. In the current session, I can see the data in the admin page, but next time I run the project, all previous datastore is lost.

我知道应用引擎有--clear_datastore运行条件,但我不想要这个功能。

I know app engine has the --clear_datastore run condition, but i dont't want this feature.

顺便提一下,本地的数据存储区文件在哪里?

By the way, where is there a local datastore file?

推荐答案

可以使用 - datastore_path = / datastore / path / dev_appserver.datastore 参数与dev_appserver.py

you can use the --datastore_path=/datastore/path/dev_appserver.datastore parameter with dev_appserver.py

- blobstore_path = / path / to / blobstore / folder 一个选项。

这篇关于每次项目运行时,应用引擎数据存储区都将自动清除的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆