Member-only story

Sorry, Amazon DynamoDB is not column-based, and it is not OLAP

LORY
7 min readMay 1, 2024

--

Another interview story.

The story

It was an architect position.

Me: “Okay let’s start the interview Here you mentioned that redesigned the database and improved System performance by 50%, could you elaborate more ?”

A: “Sure, our existing database was MySQL and it was very slow when generating reports, we needed to move into a column-based database, so we looked into OLAP.”

Me: “I see, could you explain more why OLAP makes sense for your use case ?”

A: ”Yup of course. Because OLAP is a column-based database, so if we query certain columns for the entire table and do aggregation is faster, compared to traditional OLTP, like MySQL”

Me: “Which makes sense to me, and may I know which OLAP database you switched to? what else databases have you tested?”

A: “It was dynamoDB.”

This answer shocked me. As Amazon dynamoDB is a pure NoSQL and has nothing to do with OLAP at all, I think I was being cheated! but to know more about the candidate, I continued the interview process.

Me: “Are you sure DynamoDB is column-based? And what could be the downside of a column-based database?”

A: “Yes it is. and I’m not sure about the downside yet because we just started using it, we will see.”

Me: “Okay understand, could you please share more with me about the decision-making and testing process of what databases you and your team researched and eventually made a decision to choose dynamoDB in the end ?”

A: “We looked at some OLAP, like some LSM tree-based databases: ducksDB, rocksDB, level DB, and click house, and picked dynamo DB because it was the fastest”

I wasn’t familiar with all the databases he mentioned, to be honest. but I used a bit of clickhouse in my lab project. so I asked a question about click house, and he wanted to talk about more LSM trees (maybe he prepared well) so I also asked about LSM trees to see his understanding of this.

Me: “Why do you specifically look into LSM tree? how does it relate to your use cases? and are you sure click-house is also LSM-tree based?”

A: “We looked into LSM tree-based databases because it made the write very fast — the write-ahead log mechanism, which was one of our…

--

--

LORY
LORY

Written by LORY

A channel which focusing on developer growth and self improvement

Responses (4)