开发者

Migrating objects in GAE data store with Java

开发者 https://www.devze.com 2023-02-22 06:37 出处:网络
I have an application that naturally as it grows various data model classes need to change attributes (add, rename, remove, etc). In MySQL I would just run a set of queries against the data store that

I have an application that naturally as it grows various data model classes need to change attributes (add, rename, remove, etc). In MySQL I would just run a set of queries against the data store that would alter the schemas and the data.

I don't understand what is the correct approach to do with GAE's data store. My application on the server side is written in Java.

Specifically, I would like to know how to:

1) Rename a field on an exi开发者_如何学Pythonsting object 2) Add a new field on an existing object (I think this happen automatically on new objects)

Thanks for your help.


You may want to consider using Objectify in managing the datastore; it also has the ability to update schemas of existing models quite easily.


Someone has recently created a tool that would probably do what you need: http://code.google.com/p/entity-console/

0

精彩评论

暂无评论...
验证码 换一张
取 消