GAE Memcache用于NDB似乎很低 [英] GAE Memcache Usage for NDB Seems Low

查看:119
本文介绍了GAE Memcache用于NDB似乎很低的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个带有40GB数据库的Google App Engine项目,而且NDB的阅读性能差。我注意到,我的memcache大小(在仪表板上列出)只有大约2 MB。我期望NDB隐含地更多地使用memcache来提高性能。

I have a Google App Engine project with a ~40 GB database, and I'm getting poor read performance with NDB. I've noticed that my memcache size (as listed on the dashboard) is only about 2 MB. I would expect NDB to implicitly make more use of memcache to improve performance.

有没有一种调试NDB的memcache用法的方法?

Is there a way of debugging NDB's memcache usage?

推荐答案

这个问题的表述相当糟糕 - 读取性能不佳的原因有很多,其中大部分原因是由于应用程序写得不好,但您不会告诉我们关于应用程序的任何信息。

The question is rather poorly formulated -- there are a zillion reasons for poor read performance, and most are due to a poorly written app, but you don't tell us anything about the app.

唯一可以回答的问题是最后一个问题:是否有调试NDB的memcache使用的方法?除了Sologoub的指针之外,我还建议使用Appstats来确定预期的memcache调用是否实际正在进行。阅读NDB源代码,特别是get()和put()放入context.py中也可能有所帮助。

The only question that can be answered is the final one: "Is there a way of debugging NDB's memcache usage?" In addition to Sologoub's pointers I'd suggest using Appstats to find out whether the expected memcache calls are actually being made. And reading the NDB source code, especially get() and put() in context.py, might also help.

这篇关于GAE Memcache用于NDB似乎很低的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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