A convenient way to preload data in development en

2019-04-15 00:34发布

I'm developing an application on Google App Engine using Maven. When I run the local server I would like to have some data preloaded in the datastore, such as the local user table. The server puts the datastore file under the WEB-INF/appengine-generated of the target directory and it is cleaned before every build. Is there a convenient way to do so?

1条回答
Evening l夕情丶
2楼-- · 2019-04-15 01:10

You have a couple of options:
a. backup and reload local_db.bin in your build steps
b. use the datastore.backing_store system property with:

dev_appserver.sh --jvm_flag= -Ddatastore.backing_store=\path\to\local_db.bin
查看更多
登录 后发表回答