Show Menu
Cheatography

FIT3176 - NoSQL Databases Cheat Sheet (DRAFT) by

MONASH UNIT FIT3176.

This is a draft cheat sheet. It is a work in progress and is not finished yet.

Big Data

NoSQL
Not Only SQL
3 Vs of Big Data
Volume (size), Velocity (speed), Variety (types).
Volume
Massive amount of data generated and stored.
Velocity
Speed at which data is produced, transf­erred, and processed.
Variety
Diversity of data formats and sources (text, images, videos, sensors, logs, etc.).
Data Modelling
Defining structure, relati­onships & rules for data.
Relational DB query language
SQL (Struc­tured Query Language)
ACID
Atomicity, Consis­tency, Isolation, Durability
BASE
Basically Available, Soft state, Eventual consis­tency

Scaling

Vertical Scaling (up)
Add power to one server.
Horizontal Scaling (up)
Cluster of low-cost servers (preferred for Big Data).
Normal­isation
Organising data to reduce redund­ancy, improve integrity.
Denorm­ali­sation
Trade redundancy for faster queries.

Data Model Components

Entity
Object / Class (e.g Student)
Entity Instance
Record of a entity
Attribute
Property / Field (e.g Age)
Relati­onship
Connection (e.g Student -> EnrolledIn -> Course)

MongoDB

Document Oriented Database
Subclass of key-value databases.
Document
Encoded in format such as XML, JSON, BSON.
Schema­-less
No predefined structure on the stored data & each document can have its own structure.
Collection
Group of documents.

SQL VS MongoDB

 

NoSQL Databases

Key-Value
Stores simple key/value pairs.
DynamoDB, Redis
Document
Stores JSON-like documents.
MongoDB, CouchDB
Column
Stores data by columns instead of rows.
Cassandra, BigTables
Graphs
vStores data as nodes + relati­ons­hips.
Neo4j, ArangoDB
Time Series
(not part of the unit but whatever it still is a type of NoSQL database)
Promet­heus, Timescale (postg­reSQL fork (it's great tbh))

NoSQL - Quick Overview

▪ Non-re­lat­ional and schema­-less.
▪ Supports distri­buted database archit­ect­ures.
▪ Provides high scalab­ility, and high availa­bility.
▪ Able to support very large amounts of sparse data.
▪ Designed mainly towards perfor­mance rather than transa­ction consis­tency.
 

NoSQL - Pros & Cons

SQL - Pros & Cons