SimpleDB 作为非规范化数据库
在拥有处理所有业务事务的关系数据库的环境中,使用 SimpleDB 进行所有数据查询以进行更快、更轻量级的搜索是个好主意吗?
因此,主数据存储将是一个关系数据库,它被“复制”/“转换”为 SimpleDB,以提供非常快速的只读查询,因为不需要 JOINS 和复杂的子选择。
In an environment where you have a relational database which handles all business transactions is it a good idea to utilise SimpleDB for all data queries to have faster and more lightweight search?
So the master data storage would be a relational DB which is "replicated"/"transformed" into SimpleDB to provide very fast read only queries since no JOINS and complicated subselects are needed.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
我仍然觉得难以置信,但我们的实验表明,在天气好的时候,从 EC2 实例到 simpledb 的往返平均为 300 毫秒左右!在糟糕的一天,我们发现它会下降到 1.5 秒。这是针对单个插入件的。我很乐意看到有人复制这个实验来验证这些结果,但事实上...... simpledb 除了后处理之外没有任何解决方案 - 在请求/响应周期中它只会变慢。
I am still finding it hard to believe, but our experiments show that a round trip from and EC2 instance to simpledb is averaging out to 300milliseconds or so, on a good day! On a bad day we've seen it go down to 1.5sec. This is for a single insert. I'd love to see somebody replicate the experiment to verify these results, but as it is... simpledb is no solution for anything but post processing- in the request/response cycle it would just be way to slow.
如果数据大部分是只读的,请尝试使用索引视图。否则,将数据缓存在应用程序中。
If the data is largely read-only, try using indexed views. Otherwise, cache the data in the application.
您正在考虑的事情有点过早优化的味道……
您对您的应用程序进行了基准测试吗?您是否已将搜索查询确定为性能瓶颈?您是否在数据库中正确实施了索引?
如果(这是一个很大的如果)无法使用关系数据库为用户提供合适的搜索时间,那么使用 NOSQL 可能是值得考虑的......但不是之前!
What you're considering smells of premature optimization ...
Have you benchmarked your application? Have you identified your search queries as a performance bottleneck? Have you correctly implemented indexes into your database?
IF (and that's a big if) there's no way using a relational database to offer decent search times to your users, going NOSQL might be something worth considering ... but not before !
SimpleDB 是一项很好的技术,但它的成名并不在于比关系数据库更快的查询。将查询卸载到复制的 SimpleDB 不太可能显着改善查询响应时间。
SimpleDB is a good technology but its claim to fame is not faster queries than a relational database. Offloading queries to replicated SimpleDB is not likely to significantly improve your query response time.