pros and cons of db and ndb in google app engine

2019-02-08 05:08发布

I have seen a little of this in stack overflow but I am wondering if there is any reason to use the DB entity model and what the specific pros and cons of using on or the other are.

I have read the ndb is a little faster and that it helps with caching. They have a good bit of info in the docs but don't really straight out say that ndb is better. At least I haven't found that yet.

1条回答
孤傲高冷的网名
2楼-- · 2019-02-08 05:41

As far as I can tell ndb is an evolution of db, kept seperate to maintain compatability.

Have a look at the cheat sheet, it details the main differences

https://docs.google.com/document/d/1AefylbadN456_Z7BZOpZEXDq8cR8LYu7QgI7bt5V0Iw/mobilebasic

But it does not mention the other features such as computed properties.

If you are starting a new project I see no reason not to use ndb and every reason to.

EDIT: Alt link for document: https://docs.google.com/document/d/1AefylbadN456_Z7BZOpZEXDq8cR8LYu7QgI7bt5V0Iw/edit#

查看更多
登录 后发表回答