Categories
DynamoDB tutorial

Introduction to DynamoDB database

DynamoDB introduction

In this section of the tutorial, we will learn about the basic introduction to DynamoDB.

DynamoDB is a key-value document-bIased, AWS managed database service. DynamoDB removes the need for configuration of service. Since it is fully managed by AWS there is no initial server configuration needed. All you need to do is go to the AWS console and create a table that you need. AWS DynamoDB was introduced in 2012.

DynamoDB has a lot of built-in functionality for a reliable and secure database. We will go through each of them from how to backup the database to the high availability and reliability of DynamoDB.

Since it uses a document-based key-value model, DynamoDB has a predictable performance with scale.

Introduction to some of the key features of DynamoDB

  • Predictable read/write performance
  • Multi-zone availability, which means even though a zone is not available the database is resilient to failure
  • Fully managed by AWS.
  • Built-in Backup and encryption of data
  • Highly recommended for serverless applications
  • Easy to integrate with other AWS services
  • No operational overhead.

Some drawbacks of DynamoDB

  • High Cost
  • Global indexes are eventually consistent. Which we will talk more on the indexes section.
  • Difficult to do Complex Queries.
  • No database triggers but can be compensated with DynamoDB streams.
  • No foreign key and no Joins. A Document-based database table needs to be structured in a non-relational pattern.
  • It is only available in AWS and cannot be hosted elsewhere. Compensation – DynamoDB local is there for the local machine.
  • It cannot store blobs in the database. The alternative is to use s3 to store the data and store the meta in the table.

When to choose AWS DynamoDB?

  • You are building a serverless application
  • The application needs a frequent change in capacity.
  • You do not want to do server patches and maintenance for the database.
  • You have high key-based read/write and do not need to do the complex query
  • Good for OLTP applications whereas not good for OLAP applications
  • The schema of your database changes frequently

Like any other key-value document-based store in DynamoDB, you do not need to specify the attributes of the table. The attributes are dynamic. The only attributes that you need to specify are the partition key, sort key, and the indexes. DynamoDB stores the data in partitions based on the partition key specified.

In the next section of this tutorial, we will learn how to set up a DynamoDB.

Leave a Reply

Your email address will not be published. Required fields are marked *