是dynamodb对我的用例? (批量读取) [英] Is dynamodb good for my usecase? (bulk reads)

查看:259
本文介绍了是dynamodb对我的用例? (批量读取)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我收集,用亚马逊DynamoDB 一分钱一分货供应量。

应用程序1确实或多或少符合率写的,数据是理想的键/值存储,并没有读过的数据备份。目前,其3 - 5K写入/小时,但我们推出势必会增加一次

应用2读取(从写的应用程序1中的数据)每小时1小时美元的记录,并读取每一天值得记录的一个天。最终一致性是可以接受的。

所以,我说的对承担dynamodb是不是适合我?正如我将不得不提供较高的读取率,即使我打,只有每小时几秒钟率是多少?有没有一种方法来转储记录?

目前,我使用的是MongoDB的主/从。我用的是从我的批量读取,因此,它不会影响主...但ID更愿意让别人来处理数据库架构。

解决方案
  

所以,我说的对承担dynamodb是不是适合我?

好问题 - 我不一定会得出你的结论,但你需要考虑具体的成本/性能的确,这可能会或可能不会超过你所寻找的好处

  

正如我将不得不提供较高的读取率,即使我打的   仅几秒钟率每隔一小时?

这是正确的,的您支付的基础上的能力,你保留的(见<平坦,时薪A HREF =htt​​p://aws.amazon.com/DynamoDB/#pricing相对= nofollow的>定价的),并且必须提供能力,以用于读取中遇到的最大吞吐量要求的之一小时值得记录的相应为了避免被节流。

此外,你需要调整供应能力为每日秒杀的每天都有值得记录的一个天。像往常一样对AWS有可做到这一点,但要注意相关的常见问题项目的API,如:

  • <一个href="http://aws.amazon.com/dynamodb/faqs/#Is_there_any_limit_on_how_much_I_can_change_my_provisioned_throughput_with_a_single_request"相对=nofollow>有多少,我可以用一个请求?。
  • 改变我供应的吞吐量任何限制
  • 多久可以改变我供应的吞吐量是多少?

后者是特别艰难的,只要你可以增加你的供应吞吐量只要你想经常然而 你可以每天一次降低它而已!

显然,你应该检查相关的其他可用的常见问题项目的置备吞吐量的为好,因为可能有更多的细微之处不动。

由于问题的复杂性它可能是不可避免的,充分掌握<一个概念href="http://docs.amazonwebservices.com/amazondynamodb/latest/developerguide/WorkingWithDDTables.html#ProvisionedThroughput"相对=nofollow>置备吞吐量亚马逊DynamoDB ,只要你必须考虑它的建筑智慧,以达到预期的效果。计算成本和性能的详细信息为特定用例显然将是一个不平凡的锻炼DynamoDB;)

From what i gather, with Amazon DynamoDB you pay for provisioned throughput.

Application1 does more or less consistent rate of writes, data is ideal for key/value store, and doesn't ever read the data back. At the moment its 3 - 5k writes/hour but its bound to increase once we launch.

Application2 reads (from the data written by application1) one hour worth of records every hour, and reads one days worth of records every day. Eventual consistency is acceptable.

So am i right to assume dynamodb isn't well suited for me? As in i would have to provision a high read rate, even if I hit that rate only for few seconds every hour? Is there a way to dump records?

At the moment, i'm using master/slave on mongodb. I use the slave for my batch reads, so that it doesn't effect the master... but id much rather let someone else handle the db infrastructure.

解决方案

So am i right to assume dynamodb isn't well suited for me?

Good question - I wouldn't necessarily come to your conclusion, though you'll need to account for the specific cost/performance characteristics indeed, which may or may not outweigh the benefits you are looking for.

As in i would have to provision a high read rate, even if I hit that rate only for few seconds every hour?

That's correct, You pay a flat, hourly rate based on the capacity you reserve (see Pricing) and must provision capacity to the maximum throughput requirements encountered for reading one hour worth of records accordingly in order to avoid being throttled.

In addition you'll need to adjust the provisioned capacity for the daily spike of one days worth of records every day. As usual for AWS there is an API available to do this, but be aware of the related FAQ items, e.g.:

The latter is particularly tough, insofar You can increase your provisioned throughput as often as you want, however You can decrease it once per day only!

Obviously You should review the other available FAQ items related to Provisioned Throughput as well, as there might be more subtleties still.

Given the involved complexities it's probably unavoidable to fully grasp the concept of Provisioned Throughput in Amazon DynamoDB, insofar one must account for it architecture wise in order to achieve the desired results. Calculating the cost and performance details for a particular use case is apparently going to be a non trivial exercise for DynamoDB ;)

这篇关于是dynamodb对我的用例? (批量读取)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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