SlideShare uma empresa Scribd logo
1 de 17
Date : September 28, 2017
Location : USM
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
1
Presented by:
Md. Shohel Rana
W10006485
CASSANDRA - A DISTRIBUTEDDATABASE SYSTEM
CONTENTS
• About Cassandra
• Features of Cassandra
• Architecture
• Components of Cassandra
• Cassandra Data Model
• Comparison between Data Models of Cassandra and RDBMS
• Installation
• Cassandra - CQLSH
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
2
ABOUT CASSANDRA
• Cassandra is a highly scalable, high-performance distributed
database designed to handle large amounts of data across many
commodity servers, providing high availability with no single point of
failure. It is a type of NoSQL database
• It is a column-oriented database
• Its distribution design is based on Amazon’s Dynamo and its data
model on Google’s Bigtable.
• Created at Facebook, it differs sharply from relational database
management systems.
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
3
ABOUT CASSANDRA (CONT.)
• Cassandra implements a Dynamo-style replication model with no
single point of failure, but adds a more powerful “column family” data
model.
• Cassandra is being used by some of the biggest companies such as
Facebook, Twitter, Cisco, Rackspace, ebay, Twitter, Netflix, and more
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
4
FEATURES OF CASSANDRA
• Elastic scalability - Cassandra is highly scalable; it allows to add more hardware to
accommodate more customers and more data as per requirement.
• Always on architecture - Cassandra has no single point of failure and it is continuously
available for business-critical applications that cannot afford a failure.
• Fast linear-scale performance - Cassandra is linearly scalable, i.e., it increases your
throughput as you increase the number of nodes in the cluster. Therefore, it maintains a
quick response time.
• Flexible data storage - Cassandra accommodates all possible data formats including:
structured, semi-structured, and unstructured. It can dynamically accommodate changes
to your data structures according to your need.
• Easy data distribution - Cassandra provides the flexibility to distribute data where you
need by replicating data across multiple data centers.
• Transaction support - Cassandra supports properties like Atomicity, Consistency,
Isolation, and Durability (ACID).
• Fast writes - Cassandra was designed to run on cheap commodity hardware. It performs
blazingly fast writes and can store hundreds of terabytes of data, without sacrificing the
read efficiency.
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
5
ARCHITECTURE
• One or more of the nodes in a cluster act as replicas for a given piece
of data. If it is detected that some of the nodes responded with an out-
of-date value, Cassandra will return the most recent value to the
client. After returning the most recent value, Cassandra performs a
read repair in the background to update the stale values
• Cassandra uses the Gossip Protocol in the background to allow the
nodes to communicate with each other and detect any faulty nodes in
the cluster
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
6
ARCHITECTURE (CONT.)
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
7
COMPONENTS OF CASSANDRA
• Node − It is the place where data is stored.
• Data center− It is a collection of related nodes.
• Cluster− A cluster is a component that contains one or more data centers.
• Commit log − The commit log is a crash-recovery mechanism in Cassandra. Every write
operation is written to the commit log.
• Mem-table − A mem-table is a memory-resident data structure. After commit log, the
data will be written to the mem-table. Sometimes, for a single-column family, there will be
multiple mem-tables.
• SSTable − It is a disk file to which the data is flushed from the mem-table when its
contents reach a threshold value.
• Bloomfilter− These are nothing but quick, nondeterministic, algorithms for testing
whether an element is a member of a set. It is a special kind of cache. Bloom filters are
accessed after every query.
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
8
CASSANDRA DATA MODEL
• Cluster: Cassandra database is distributed over several machines that
operate together. The outermost container is known as the Cluster
• KEYSPACE: outermost container for data in Cassandra
Replication factor− It is the number of machines in the cluster that will receive
copies of the same data.
Replica placement strategy − It is nothing but the strategy to place replicas in the
ring. We have strategies such as simple strategy (rack-aware strategy), old network
topology strategy (rack-aware strategy), and network topology strategy (datacenter-
shared strategy).
Column families − Keyspace is a container for a list of one or more column families.
A column family, in turn, is a container of a collection of rows
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
9
CASSANDRA DATA MODEL (CONT.)
• Column Family: A column family is a container for an ordered collection of
rows. Each row, in turn, is an ordered collection of columns
• Column: A column is the basic data structure of Cassandra with three
values, namely key or column name, value, and a time stamp
• SuperColumn: A super column is a special column, therefore, it is also a
key-value pair. But a super column stores a map of sub-columns.
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
10
COMPARISON BETWEEN DATA MODELS OF
CASSANDRA AND RDBMS
RDBMS Cassandra
RDBMS deals with structured data. Cassandra deals with unstructured data.
It has a fixed schema. Cassandra has a flexible schema.
In RDBMS, a table is an array of arrays. (ROW
x COLUMN)
In Cassandra, a table is a list of “nested key-
value pairs”. (ROW x COLUMN key x COLUMN
value)
Database is the outermost container that
contains data corresponding to an application.
Keyspace is the outermost container that
contains data corresponding to an application.
Tables are the entities of a database. Tables or column families are the entity of a
keyspace.
Row is an individual record in RDBMS. Row is a unit of replication in Cassandra.
Column represents the attributes of a relation. Column is a unit of storage in Cassandra.
RDBMS supports the concepts of foreign keys,
joins.
Relationships are represented using
collections.
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
11
INSTALLATION
• Pre-requisites: Java JDK, Python, Client drivers (Java ▪Python ▪Ruby ▪C# /
.NET ▪Nodejs ▪PHP ▪C++ ▪Scala ▪Clojure ▪Erlang ▪Go ▪Haskell ▪Rust ▪
Perl)
• Installation Methods:
 Installation from binary tarball files
 Installation from Debian packages.
 Installation using Windows Installer (preferred)
• Installation Procedure (Windows System): See Documents
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
12
CASSANDRA - CQLSH
• Cassandra provides a prompt Cassandra query language shell (CQLSH)
that allows users to communicate with it. Using this shell, you can execute
Cassandra Query Language (CQL)
• CQLSHCommands:
• Documented Shell Commands: HELP, COPY, DESCRIBE, TRACING, SHOW etc.
• CQL Data Definition Commands: CREATE KEYSPACE, ALTER, USE, DROP,
TRUNCATE etc.
• CQL Data Manipulation Commands: INSERT, UPDATE, DELETE, BATCH etc.
• CQL Clauses: SELECT, WHERE, ORDER BY etc.
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
13
CASSANDRA – CQLSH (CONT.)
• CQL Example:
• Create KEYSPACE: CREATE KEYSPACE people WITH REPLICATION = <'class' :
'SimpleStrategy', 'replication_factor' : 3>;
• Create Table: USE "people"; CREATE TABLE "employees" (id uuid, name varchar,
email, PRIMARY KEY (id, email));
• Insert Data INSERT INTO employees(id, name, email) VALUES(now(), ‘X’, ‘a@a.com’);
• Data Retrieve: SELECT * FROM employees;
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
14
DATA MONITORING
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
15
LIMITATION
• DataStax Versioning
• Lac of more machines to make multiple nodes as well as multiple
clusters
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
16
THANKS!
QUESTION?
CSC 733: DISTRIBUTEDDATABASE SYSTEMS
17

Mais conteúdo relacionado

Mais procurados

Introduction to Apache Cassandra
Introduction to Apache CassandraIntroduction to Apache Cassandra
Introduction to Apache CassandraRobert Stupp
 
Cassandra architecture
Cassandra architectureCassandra architecture
Cassandra architectureT Jake Luciani
 
Presentation of Apache Cassandra
Presentation of Apache Cassandra Presentation of Apache Cassandra
Presentation of Apache Cassandra Nikiforos Botis
 
Introduction to NoSQL & Apache Cassandra
Introduction to NoSQL & Apache CassandraIntroduction to NoSQL & Apache Cassandra
Introduction to NoSQL & Apache CassandraChetan Baheti
 
Understanding Data Partitioning and Replication in Apache Cassandra
Understanding Data Partitioning and Replication in Apache CassandraUnderstanding Data Partitioning and Replication in Apache Cassandra
Understanding Data Partitioning and Replication in Apache CassandraDataStax
 
Apache Cassandra @Geneva JUG 2013.02.26
Apache Cassandra @Geneva JUG 2013.02.26Apache Cassandra @Geneva JUG 2013.02.26
Apache Cassandra @Geneva JUG 2013.02.26Benoit Perroud
 
NOSQL Database: Apache Cassandra
NOSQL Database: Apache CassandraNOSQL Database: Apache Cassandra
NOSQL Database: Apache CassandraFolio3 Software
 
Evaluating Apache Cassandra as a Cloud Database
Evaluating Apache Cassandra as a Cloud DatabaseEvaluating Apache Cassandra as a Cloud Database
Evaluating Apache Cassandra as a Cloud DatabaseDataStax
 
Apache Cassandra at the Geek2Geek Berlin
Apache Cassandra at the Geek2Geek BerlinApache Cassandra at the Geek2Geek Berlin
Apache Cassandra at the Geek2Geek BerlinChristian Johannsen
 
Cassandra concepts, patterns and anti-patterns
Cassandra concepts, patterns and anti-patternsCassandra concepts, patterns and anti-patterns
Cassandra concepts, patterns and anti-patternsDave Gardner
 
Cassandra: Open Source Bigtable + Dynamo
Cassandra: Open Source Bigtable + DynamoCassandra: Open Source Bigtable + Dynamo
Cassandra: Open Source Bigtable + Dynamojbellis
 
Column db dol
Column db dolColumn db dol
Column db dolpoojabi
 
Introduction to Cassandra
Introduction to CassandraIntroduction to Cassandra
Introduction to CassandraGokhan Atil
 

Mais procurados (20)

Introduction to Apache Cassandra
Introduction to Apache CassandraIntroduction to Apache Cassandra
Introduction to Apache Cassandra
 
Cassandra architecture
Cassandra architectureCassandra architecture
Cassandra architecture
 
Presentation of Apache Cassandra
Presentation of Apache Cassandra Presentation of Apache Cassandra
Presentation of Apache Cassandra
 
Introduction to NoSQL & Apache Cassandra
Introduction to NoSQL & Apache CassandraIntroduction to NoSQL & Apache Cassandra
Introduction to NoSQL & Apache Cassandra
 
Cassandra Database
Cassandra DatabaseCassandra Database
Cassandra Database
 
Cassandra training
Cassandra trainingCassandra training
Cassandra training
 
Understanding Data Partitioning and Replication in Apache Cassandra
Understanding Data Partitioning and Replication in Apache CassandraUnderstanding Data Partitioning and Replication in Apache Cassandra
Understanding Data Partitioning and Replication in Apache Cassandra
 
Apache Cassandra @Geneva JUG 2013.02.26
Apache Cassandra @Geneva JUG 2013.02.26Apache Cassandra @Geneva JUG 2013.02.26
Apache Cassandra @Geneva JUG 2013.02.26
 
Cassandra Architecture FTW
Cassandra Architecture FTWCassandra Architecture FTW
Cassandra Architecture FTW
 
NOSQL Database: Apache Cassandra
NOSQL Database: Apache CassandraNOSQL Database: Apache Cassandra
NOSQL Database: Apache Cassandra
 
Evaluating Apache Cassandra as a Cloud Database
Evaluating Apache Cassandra as a Cloud DatabaseEvaluating Apache Cassandra as a Cloud Database
Evaluating Apache Cassandra as a Cloud Database
 
Apache Cassandra at the Geek2Geek Berlin
Apache Cassandra at the Geek2Geek BerlinApache Cassandra at the Geek2Geek Berlin
Apache Cassandra at the Geek2Geek Berlin
 
Cassandra concepts, patterns and anti-patterns
Cassandra concepts, patterns and anti-patternsCassandra concepts, patterns and anti-patterns
Cassandra concepts, patterns and anti-patterns
 
Intro to Cassandra
Intro to CassandraIntro to Cassandra
Intro to Cassandra
 
Cassandra: Open Source Bigtable + Dynamo
Cassandra: Open Source Bigtable + DynamoCassandra: Open Source Bigtable + Dynamo
Cassandra: Open Source Bigtable + Dynamo
 
Column db dol
Column db dolColumn db dol
Column db dol
 
Cassandra
CassandraCassandra
Cassandra
 
No sql
No sqlNo sql
No sql
 
Cassandra ppt 2
Cassandra ppt 2Cassandra ppt 2
Cassandra ppt 2
 
Introduction to Cassandra
Introduction to CassandraIntroduction to Cassandra
Introduction to Cassandra
 

Semelhante a Cassandra - A Distributed Database System

04-Introduction-to-CassandraDB-.pdf
04-Introduction-to-CassandraDB-.pdf04-Introduction-to-CassandraDB-.pdf
04-Introduction-to-CassandraDB-.pdfhothyfa
 
Appache Cassandra
Appache Cassandra  Appache Cassandra
Appache Cassandra nehabsairam
 
Cassandra - A decentralized storage system
Cassandra - A decentralized storage systemCassandra - A decentralized storage system
Cassandra - A decentralized storage systemArunit Gupta
 
NoSQL - Cassandra & MongoDB.pptx
NoSQL -  Cassandra & MongoDB.pptxNoSQL -  Cassandra & MongoDB.pptx
NoSQL - Cassandra & MongoDB.pptxNaveen Kumar
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningVitsRangannavar
 
Cassandra - A Basic Introduction Guide
Cassandra - A Basic Introduction GuideCassandra - A Basic Introduction Guide
Cassandra - A Basic Introduction GuideMohammed Fazuluddin
 
The No SQL Principles and Basic Application Of Casandra Model
The No SQL Principles and Basic Application Of Casandra ModelThe No SQL Principles and Basic Application Of Casandra Model
The No SQL Principles and Basic Application Of Casandra ModelRishikese MR
 
CASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEM
CASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEMCASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEM
CASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEMIJCI JOURNAL
 
Cassandra implementation for collecting data and presenting data
Cassandra implementation for collecting data and presenting dataCassandra implementation for collecting data and presenting data
Cassandra implementation for collecting data and presenting dataChen Robert
 
Apache Cassandra introduction
Apache Cassandra introductionApache Cassandra introduction
Apache Cassandra introductionfardinjamshidi
 
Cassandra for mission critical data
Cassandra for mission critical dataCassandra for mission critical data
Cassandra for mission critical dataOleksandr Semenov
 
Cassandra advanced part-ll
Cassandra advanced part-llCassandra advanced part-ll
Cassandra advanced part-llachudhivi
 
cassandra_presentation_final
cassandra_presentation_finalcassandra_presentation_final
cassandra_presentation_finalSergioBruno21
 

Semelhante a Cassandra - A Distributed Database System (20)

04-Introduction-to-CassandraDB-.pdf
04-Introduction-to-CassandraDB-.pdf04-Introduction-to-CassandraDB-.pdf
04-Introduction-to-CassandraDB-.pdf
 
Appache Cassandra
Appache Cassandra  Appache Cassandra
Appache Cassandra
 
Cassandra tutorial
Cassandra tutorialCassandra tutorial
Cassandra tutorial
 
Cassandra Learning
Cassandra LearningCassandra Learning
Cassandra Learning
 
Cassndra (4).pptx
Cassndra (4).pptxCassndra (4).pptx
Cassndra (4).pptx
 
Cassandra - A decentralized storage system
Cassandra - A decentralized storage systemCassandra - A decentralized storage system
Cassandra - A decentralized storage system
 
cassandra.pptx
cassandra.pptxcassandra.pptx
cassandra.pptx
 
NoSQL - Cassandra & MongoDB.pptx
NoSQL -  Cassandra & MongoDB.pptxNoSQL -  Cassandra & MongoDB.pptx
NoSQL - Cassandra & MongoDB.pptx
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learning
 
Cassandra - A Basic Introduction Guide
Cassandra - A Basic Introduction GuideCassandra - A Basic Introduction Guide
Cassandra - A Basic Introduction Guide
 
The No SQL Principles and Basic Application Of Casandra Model
The No SQL Principles and Basic Application Of Casandra ModelThe No SQL Principles and Basic Application Of Casandra Model
The No SQL Principles and Basic Application Of Casandra Model
 
CASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEM
CASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEMCASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEM
CASSANDRA A DISTRIBUTED NOSQL DATABASE FOR HOTEL MANAGEMENT SYSTEM
 
Why Cassandra?
Why Cassandra?Why Cassandra?
Why Cassandra?
 
NoSQL Session II
NoSQL Session IINoSQL Session II
NoSQL Session II
 
Cassandra implementation for collecting data and presenting data
Cassandra implementation for collecting data and presenting dataCassandra implementation for collecting data and presenting data
Cassandra implementation for collecting data and presenting data
 
Apache Cassandra introduction
Apache Cassandra introductionApache Cassandra introduction
Apache Cassandra introduction
 
Cassandra for mission critical data
Cassandra for mission critical dataCassandra for mission critical data
Cassandra for mission critical data
 
Apache cassandra
Apache cassandraApache cassandra
Apache cassandra
 
Cassandra advanced part-ll
Cassandra advanced part-llCassandra advanced part-ll
Cassandra advanced part-ll
 
cassandra_presentation_final
cassandra_presentation_finalcassandra_presentation_final
cassandra_presentation_final
 

Mais de Md. Shohel Rana

A Proposed PST Model for Enhancing E-Learning Experiences
A Proposed PST Model for Enhancing E-Learning ExperiencesA Proposed PST Model for Enhancing E-Learning Experiences
A Proposed PST Model for Enhancing E-Learning ExperiencesMd. Shohel Rana
 
Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...
Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...
Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...Md. Shohel Rana
 
An Enhanced Model for Inpainting on Digital Images Using Dynamic Masking
An Enhanced Model for Inpainting on Digital Images Using Dynamic MaskingAn Enhanced Model for Inpainting on Digital Images Using Dynamic Masking
An Enhanced Model for Inpainting on Digital Images Using Dynamic MaskingMd. Shohel Rana
 
Comparing the Performance of Different Ultrasonic Image Enhancement Technique...
Comparing the Performance of Different Ultrasonic Image Enhancement Technique...Comparing the Performance of Different Ultrasonic Image Enhancement Technique...
Comparing the Performance of Different Ultrasonic Image Enhancement Technique...Md. Shohel Rana
 
Malware analysis on android using supervised machine learning techniques
Malware analysis on android using supervised machine learning techniquesMalware analysis on android using supervised machine learning techniques
Malware analysis on android using supervised machine learning techniquesMd. Shohel Rana
 
De-convolution on Digital Images
De-convolution on Digital ImagesDe-convolution on Digital Images
De-convolution on Digital ImagesMd. Shohel Rana
 

Mais de Md. Shohel Rana (7)

A Proposed PST Model for Enhancing E-Learning Experiences
A Proposed PST Model for Enhancing E-Learning ExperiencesA Proposed PST Model for Enhancing E-Learning Experiences
A Proposed PST Model for Enhancing E-Learning Experiences
 
Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...
Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...
Speckle Noise Reduction in Ultrasound Images using Adaptive and Anisotropic D...
 
An Enhanced Model for Inpainting on Digital Images Using Dynamic Masking
An Enhanced Model for Inpainting on Digital Images Using Dynamic MaskingAn Enhanced Model for Inpainting on Digital Images Using Dynamic Masking
An Enhanced Model for Inpainting on Digital Images Using Dynamic Masking
 
Comparing the Performance of Different Ultrasonic Image Enhancement Technique...
Comparing the Performance of Different Ultrasonic Image Enhancement Technique...Comparing the Performance of Different Ultrasonic Image Enhancement Technique...
Comparing the Performance of Different Ultrasonic Image Enhancement Technique...
 
Malware analysis on android using supervised machine learning techniques
Malware analysis on android using supervised machine learning techniquesMalware analysis on android using supervised machine learning techniques
Malware analysis on android using supervised machine learning techniques
 
Visual Techniques
Visual TechniquesVisual Techniques
Visual Techniques
 
De-convolution on Digital Images
De-convolution on Digital ImagesDe-convolution on Digital Images
De-convolution on Digital Images
 

Último

CebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptxCebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptxolyaivanovalion
 
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...amitlee9823
 
Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxolyaivanovalion
 
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightCheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightDelhi Call girls
 
Call Girls In Attibele ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Attibele ☎ 7737669865 🥵 Book Your One night StandCall Girls In Attibele ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Attibele ☎ 7737669865 🥵 Book Your One night Standamitlee9823
 
Probability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter LessonsProbability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter LessonsJoseMangaJr1
 
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...amitlee9823
 
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteedamy56318795
 
Mature dropshipping via API with DroFx.pptx
Mature dropshipping via API with DroFx.pptxMature dropshipping via API with DroFx.pptx
Mature dropshipping via API with DroFx.pptxolyaivanovalion
 
Invezz.com - Grow your wealth with trading signals
Invezz.com - Grow your wealth with trading signalsInvezz.com - Grow your wealth with trading signals
Invezz.com - Grow your wealth with trading signalsInvezz1
 
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -Pooja Nehwal
 
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...SUHANI PANDEY
 
April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysismanisha194592
 
Call Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night StandCall Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night Standamitlee9823
 
FESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfFESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfMarinCaroMartnezBerg
 
Accredited-Transport-Cooperatives-Jan-2021-Web.pdf
Accredited-Transport-Cooperatives-Jan-2021-Web.pdfAccredited-Transport-Cooperatives-Jan-2021-Web.pdf
Accredited-Transport-Cooperatives-Jan-2021-Web.pdfadriantubila
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionfulawalesam
 

Último (20)

CebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptxCebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptx
 
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
 
Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFx
 
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightCheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
 
Call Girls In Attibele ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Attibele ☎ 7737669865 🥵 Book Your One night StandCall Girls In Attibele ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Attibele ☎ 7737669865 🥵 Book Your One night Stand
 
Probability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter LessonsProbability Grade 10 Third Quarter Lessons
Probability Grade 10 Third Quarter Lessons
 
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men  🔝Bangalore🔝   Esc...
➥🔝 7737669865 🔝▻ Bangalore Call-girls in Women Seeking Men 🔝Bangalore🔝 Esc...
 
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
 
Mature dropshipping via API with DroFx.pptx
Mature dropshipping via API with DroFx.pptxMature dropshipping via API with DroFx.pptx
Mature dropshipping via API with DroFx.pptx
 
Invezz.com - Grow your wealth with trading signals
Invezz.com - Grow your wealth with trading signalsInvezz.com - Grow your wealth with trading signals
Invezz.com - Grow your wealth with trading signals
 
Predicting Loan Approval: A Data Science Project
Predicting Loan Approval: A Data Science ProjectPredicting Loan Approval: A Data Science Project
Predicting Loan Approval: A Data Science Project
 
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
 
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
 
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
 
April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysis
 
Call Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night StandCall Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Doddaballapur Road ☎ 7737669865 🥵 Book Your One night Stand
 
FESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfFESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdf
 
Accredited-Transport-Cooperatives-Jan-2021-Web.pdf
Accredited-Transport-Cooperatives-Jan-2021-Web.pdfAccredited-Transport-Cooperatives-Jan-2021-Web.pdf
Accredited-Transport-Cooperatives-Jan-2021-Web.pdf
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interaction
 
Call Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts Service
Call Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts ServiceCall Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts Service
Call Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts Service
 

Cassandra - A Distributed Database System

  • 1. Date : September 28, 2017 Location : USM CSC 733: DISTRIBUTEDDATABASE SYSTEMS 1 Presented by: Md. Shohel Rana W10006485 CASSANDRA - A DISTRIBUTEDDATABASE SYSTEM
  • 2. CONTENTS • About Cassandra • Features of Cassandra • Architecture • Components of Cassandra • Cassandra Data Model • Comparison between Data Models of Cassandra and RDBMS • Installation • Cassandra - CQLSH CSC 733: DISTRIBUTEDDATABASE SYSTEMS 2
  • 3. ABOUT CASSANDRA • Cassandra is a highly scalable, high-performance distributed database designed to handle large amounts of data across many commodity servers, providing high availability with no single point of failure. It is a type of NoSQL database • It is a column-oriented database • Its distribution design is based on Amazon’s Dynamo and its data model on Google’s Bigtable. • Created at Facebook, it differs sharply from relational database management systems. CSC 733: DISTRIBUTEDDATABASE SYSTEMS 3
  • 4. ABOUT CASSANDRA (CONT.) • Cassandra implements a Dynamo-style replication model with no single point of failure, but adds a more powerful “column family” data model. • Cassandra is being used by some of the biggest companies such as Facebook, Twitter, Cisco, Rackspace, ebay, Twitter, Netflix, and more CSC 733: DISTRIBUTEDDATABASE SYSTEMS 4
  • 5. FEATURES OF CASSANDRA • Elastic scalability - Cassandra is highly scalable; it allows to add more hardware to accommodate more customers and more data as per requirement. • Always on architecture - Cassandra has no single point of failure and it is continuously available for business-critical applications that cannot afford a failure. • Fast linear-scale performance - Cassandra is linearly scalable, i.e., it increases your throughput as you increase the number of nodes in the cluster. Therefore, it maintains a quick response time. • Flexible data storage - Cassandra accommodates all possible data formats including: structured, semi-structured, and unstructured. It can dynamically accommodate changes to your data structures according to your need. • Easy data distribution - Cassandra provides the flexibility to distribute data where you need by replicating data across multiple data centers. • Transaction support - Cassandra supports properties like Atomicity, Consistency, Isolation, and Durability (ACID). • Fast writes - Cassandra was designed to run on cheap commodity hardware. It performs blazingly fast writes and can store hundreds of terabytes of data, without sacrificing the read efficiency. CSC 733: DISTRIBUTEDDATABASE SYSTEMS 5
  • 6. ARCHITECTURE • One or more of the nodes in a cluster act as replicas for a given piece of data. If it is detected that some of the nodes responded with an out- of-date value, Cassandra will return the most recent value to the client. After returning the most recent value, Cassandra performs a read repair in the background to update the stale values • Cassandra uses the Gossip Protocol in the background to allow the nodes to communicate with each other and detect any faulty nodes in the cluster CSC 733: DISTRIBUTEDDATABASE SYSTEMS 6
  • 7. ARCHITECTURE (CONT.) CSC 733: DISTRIBUTEDDATABASE SYSTEMS 7
  • 8. COMPONENTS OF CASSANDRA • Node − It is the place where data is stored. • Data center− It is a collection of related nodes. • Cluster− A cluster is a component that contains one or more data centers. • Commit log − The commit log is a crash-recovery mechanism in Cassandra. Every write operation is written to the commit log. • Mem-table − A mem-table is a memory-resident data structure. After commit log, the data will be written to the mem-table. Sometimes, for a single-column family, there will be multiple mem-tables. • SSTable − It is a disk file to which the data is flushed from the mem-table when its contents reach a threshold value. • Bloomfilter− These are nothing but quick, nondeterministic, algorithms for testing whether an element is a member of a set. It is a special kind of cache. Bloom filters are accessed after every query. CSC 733: DISTRIBUTEDDATABASE SYSTEMS 8
  • 9. CASSANDRA DATA MODEL • Cluster: Cassandra database is distributed over several machines that operate together. The outermost container is known as the Cluster • KEYSPACE: outermost container for data in Cassandra Replication factor− It is the number of machines in the cluster that will receive copies of the same data. Replica placement strategy − It is nothing but the strategy to place replicas in the ring. We have strategies such as simple strategy (rack-aware strategy), old network topology strategy (rack-aware strategy), and network topology strategy (datacenter- shared strategy). Column families − Keyspace is a container for a list of one or more column families. A column family, in turn, is a container of a collection of rows CSC 733: DISTRIBUTEDDATABASE SYSTEMS 9
  • 10. CASSANDRA DATA MODEL (CONT.) • Column Family: A column family is a container for an ordered collection of rows. Each row, in turn, is an ordered collection of columns • Column: A column is the basic data structure of Cassandra with three values, namely key or column name, value, and a time stamp • SuperColumn: A super column is a special column, therefore, it is also a key-value pair. But a super column stores a map of sub-columns. CSC 733: DISTRIBUTEDDATABASE SYSTEMS 10
  • 11. COMPARISON BETWEEN DATA MODELS OF CASSANDRA AND RDBMS RDBMS Cassandra RDBMS deals with structured data. Cassandra deals with unstructured data. It has a fixed schema. Cassandra has a flexible schema. In RDBMS, a table is an array of arrays. (ROW x COLUMN) In Cassandra, a table is a list of “nested key- value pairs”. (ROW x COLUMN key x COLUMN value) Database is the outermost container that contains data corresponding to an application. Keyspace is the outermost container that contains data corresponding to an application. Tables are the entities of a database. Tables or column families are the entity of a keyspace. Row is an individual record in RDBMS. Row is a unit of replication in Cassandra. Column represents the attributes of a relation. Column is a unit of storage in Cassandra. RDBMS supports the concepts of foreign keys, joins. Relationships are represented using collections. CSC 733: DISTRIBUTEDDATABASE SYSTEMS 11
  • 12. INSTALLATION • Pre-requisites: Java JDK, Python, Client drivers (Java ▪Python ▪Ruby ▪C# / .NET ▪Nodejs ▪PHP ▪C++ ▪Scala ▪Clojure ▪Erlang ▪Go ▪Haskell ▪Rust ▪ Perl) • Installation Methods:  Installation from binary tarball files  Installation from Debian packages.  Installation using Windows Installer (preferred) • Installation Procedure (Windows System): See Documents CSC 733: DISTRIBUTEDDATABASE SYSTEMS 12
  • 13. CASSANDRA - CQLSH • Cassandra provides a prompt Cassandra query language shell (CQLSH) that allows users to communicate with it. Using this shell, you can execute Cassandra Query Language (CQL) • CQLSHCommands: • Documented Shell Commands: HELP, COPY, DESCRIBE, TRACING, SHOW etc. • CQL Data Definition Commands: CREATE KEYSPACE, ALTER, USE, DROP, TRUNCATE etc. • CQL Data Manipulation Commands: INSERT, UPDATE, DELETE, BATCH etc. • CQL Clauses: SELECT, WHERE, ORDER BY etc. CSC 733: DISTRIBUTEDDATABASE SYSTEMS 13
  • 14. CASSANDRA – CQLSH (CONT.) • CQL Example: • Create KEYSPACE: CREATE KEYSPACE people WITH REPLICATION = <'class' : 'SimpleStrategy', 'replication_factor' : 3>; • Create Table: USE "people"; CREATE TABLE "employees" (id uuid, name varchar, email, PRIMARY KEY (id, email)); • Insert Data INSERT INTO employees(id, name, email) VALUES(now(), ‘X’, ‘a@a.com’); • Data Retrieve: SELECT * FROM employees; CSC 733: DISTRIBUTEDDATABASE SYSTEMS 14
  • 15. DATA MONITORING CSC 733: DISTRIBUTEDDATABASE SYSTEMS 15
  • 16. LIMITATION • DataStax Versioning • Lac of more machines to make multiple nodes as well as multiple clusters CSC 733: DISTRIBUTEDDATABASE SYSTEMS 16