How to do basic aggregation with DynamoDB?

How is aggregation achieved with dynamodb? Mongodb and couchbase have map reduction support.

Suppose we are building a technical blog where users can publish articles. And say articles can be tagged.

user
{
    id : 1235,
    name : "John",
    ...
}

article
{
    id : 789,
    title: "dynamodb use cases",
    author : 12345 //userid
    tags : ["dynamodb","aws","nosql","document database"]
}

In the user interface, we want to display the current user tags and the corresponding score.

How to achieve the next aggregation?

{
    userid : 12,
    tag_stats:{
        "dynamodb" : 3,
        "nosql" : 8
    }
}

We will provide this data through the rest api, and this will be called often. How this information is shown on the main page of the application.

  • I can think of extracting all documents and doing aggregation at the application level. But I feel that my readable power units will be exhausted.
  • You can use tools such as EMR, redshift, bigquery, aws lambda. But I think this is for datawarehousing purposes.

. , dynamodb , .

+17
2

: "" . . . .

:

, , . , , ( , , 20% RCU , 100%), ,

Redshift, Hive , . Redshift , Hive Map-Reduce. , Redshift Hive RCU.

+19

DynamoDB. DynamoDB, DynamoDB. DynamoDB - , , , , ..

. S3 DynamoDB-Glue-S3 https://aws.amazon.com/about-aws/whats-new/2018/07/aws-glue-now-supports-reading-from-amazon- /. AWS Athena SQL-, . , , SQL , .

Rockset DynamoDB. , Decore, https://rockset.com/blog/case-study-decore-uses-rockset-for-search-and-analytics-on-dynamodb/. , SQL- Rockset .

0

All Articles