SlideShare a Scribd company logo
1 of 27
Download to read offline
Hoàng	
  Anh	
  Tú	
  
NoSQL
Introduction to NoSQL
Hoàng	
  Anh	
  Tú	
   1	
  
Introduc6on	
  	
  to	
  NoSQL	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
1An	
  Overview	
  
of	
  NoSQL	
  	
  
	
  
	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
2Characteris8cs	
  
of	
  NoSQL	
  
	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
3NoSQL	
  Storage	
  
Types	
  
	
  	
  	
  	
  	
  	
  	
  	
  
 	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  
1 AN	
  OVERVIEW	
  OF	
  NOSQL	
  	
  
Hoàng	
  Anh	
  Tú	
   3	
  
What	
  is	
  NoSQL?	
  
Hoàng	
  Anh	
  Tú	
   4	
  
A	
  NoSQL	
  (o:en	
  interpreted	
  as	
  Not	
  Only	
  SQL)	
  
database	
  provides	
  a	
  mechanism	
  for	
  storage	
  and	
  
retrieval	
  of	
  data	
  that	
  is	
  modeled	
  in	
  means	
  other	
  
than	
  the	
  tabular	
  rela6ons	
  used	
  in	
  rela6onal	
  
databases.	
  
History	
  
Hoàng	
  Anh	
  Tú	
   5	
  
Billions	
  of	
  requests	
  a	
  month	
  
RDBMS	
  limits:	
  
-­‐  scalability	
  
-­‐  paralleliza6on	
  	
  
-­‐  cost	
  	
  
the	
  data	
  set	
  is	
  minimally	
  cross-­‐referenced	
  
GFS	
   Chubby	
  MapReduce	
  
Big	
  Table	
  
Lucene	
   Hadoop	
   Cassandra	
  
Pig	
  
2003	
   2006	
  2004	
  1999	
   2005	
   2008	
  
CAP	
  Theorem	
  
Hoàng	
  Anh	
  Tú	
   6	
  
all	
  nodes	
  see	
  the	
  same	
  
data	
  at	
  the	
  same	
  6me	
  
A	
  non-­‐failing	
  node	
  will	
  
return	
  a	
  reasonable	
  
response	
  within	
  a	
  
reasonable	
  amount	
  of	
  6me	
  
(no	
  error	
  or	
  6meout)	
  
The	
  system	
  will	
  con6nue	
  to	
  
func6on	
  when	
  network	
  
par66ons	
  occur	
  
CP	
  vs	
  AP	
  
Hoàng	
  Anh	
  Tú	
   7	
  
Consistency/Par66on	
  Tolerance	
   Availability/Par66on	
  Tolerance	
  
ACID	
  vs	
  BASE	
  
•  Basic	
  availability:	
  Each	
  request	
  is	
  guaranteed	
  
a	
  response—successful	
  or	
  failed	
  execu6on.	
  	
  
•  SoL	
  state:	
  The	
  state	
  of	
  the	
  system	
  may	
  
change	
  over	
  6me,	
  at	
  6mes	
  without	
  any	
  input	
  
(for	
  eventual	
  consistency).	
  	
  
•  Eventual	
  consistency:	
  The	
  database	
  may	
  be	
  
momentarily	
  inconsistent	
  but	
  will	
  be	
  
consistent	
  eventually.	
  	
  
Hoàng	
  Anh	
  Tú	
   8	
  
Why	
  NoSQL?	
  
•  Schemaless	
  data	
  representa8on	
  	
  
•  Development	
  8me	
  
•  Speed	
  	
  
•  Plan	
  ahead	
  for	
  scalability	
  	
  
Hoàng	
  Anh	
  Tú	
   9	
  
List	
  of	
  NoSQL	
  Databases	
  
Hoàng	
  Anh	
  Tú	
   10	
  
 	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  
2 CHARACTERISTICS	
  OF	
  NOSQL	
  
Hoàng	
  Anh	
  Tú	
   11	
  
Applica8on	
  
Hoàng	
  Anh	
  Tú	
   12	
  
RDBMS	
  Approach	
  
•  Iden8fy	
  actors	
  	
  
•  Define	
  models	
  	
  
•  Define	
  en88es	
  	
  
•  Define	
  rela8onships	
  	
  
•  Program	
  database	
  and	
  applica8on	
  	
  
•  Iterate	
  	
  
Hoàng	
  Anh	
  Tú	
   13	
  
En8ty	
  Rela8onship	
  Diagram	
  
Hoàng	
  Anh	
  Tú	
   14	
  
Challenges	
  
•  Schema	
  flexibility:	
  the	
  schema	
  is	
  needed	
  before	
  implemen6ng	
  the	
  
applica6on.	
  Upda6ng	
  schema	
  is	
  hard	
  especially	
  when	
  edi6ng	
  the	
  exis6ng	
  
tables’	
  schema.	
  
•  Complex	
  queries:	
  the	
  tables	
  are	
  designed	
  denormalized	
  which	
  means	
  that	
  
the	
  developers	
  end	
  up	
  wri6ng	
  complex	
  so-­‐called	
  JOIN	
  queries	
  	
  
•  Data	
  update:	
  Upda6ng	
  data	
  across	
  tables	
  is	
  probably	
  one	
  of	
  the	
  more	
  
complex	
  scenarios	
  especially	
  if	
  they	
  are	
  to	
  be	
  a	
  part	
  of	
  the	
  transac6on.	
  
Note	
  that	
  keeping	
  the	
  transac6on	
  open	
  for	
  a	
  long	
  dura6on	
  hampers	
  the	
  
performance	
  	
  
•  Scalability	
  	
  
–  What	
  is	
  the	
  6me	
  taken	
  to	
  synchronize	
  the	
  data	
  across	
  physical	
  database	
  
instances?	
  	
  
–  What	
  is	
  the	
  6me	
  taken	
  to	
  synchronize	
  the	
  data	
  across	
  datacenters?	
  	
  
–  What	
  is	
  the	
  bandwidth	
  requirement	
  to	
  synchronize	
  data?	
  Is	
  the	
  data	
  
exchanged	
  op6mized?	
  	
  
–  	
  What	
  is	
  the	
  latency	
  when	
  any	
  update	
  is	
  synchronized	
  across	
  servers?	
  
Typically,	
  the	
  records	
  will	
  be	
  locked	
  during	
  an	
  update.	
  	
  
Hoàng	
  Anh	
  Tú	
   15	
  
NoSQL	
  Approach	
  
•  Schema	
  flexibility:	
  allows	
  flexibility	
  of	
  adding	
  one	
  
or	
  more	
  columns	
  as	
  required,	
  on	
  the	
  fly	
  	
  	
  
•  Complex	
  queries:	
  NoSQL	
  databases	
  do	
  not	
  have	
  
support	
  for	
  rela6onships	
  or	
  foreign	
  keys	
  	
  
•  Data	
  update:	
  synchroniza6on	
  with	
  conflict	
  
resolu6on	
  and	
  eventually,	
  consistency	
  across	
  the	
  
datacenters	
  within	
  an	
  acceptable	
  6me	
  that	
  would	
  
run	
  in	
  few	
  milliseconds	
  	
  
•  Scalability	
  
–  Neilix	
  moved	
  from	
  Oracle	
  RDBMS	
  to	
  Apache	
  
Cassandra,	
  and	
  they	
  could	
  achieve	
  over	
  a	
  million	
  
writes	
  per	
  second1.	
  	
  
Hoàng	
  Anh	
  Tú	
   16	
  
1hjp://www.slideshare.net/hluu/neilix-­‐	
  moving-­‐to-­‐cloud	
  
 	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
	
  	
  	
  	
  	
  	
  	
  	
  
3 NOSQL	
  STORAGE	
  TYPES	
  
Hoàng	
  Anh	
  Tú	
   17	
  
Column-­‐oriented	
  
Hoàng	
  Anh	
  Tú	
   18	
  
SM1,Anuj,Sharma,45,10000000	
  
MM2,Anand,,34,5000000	
  
T3,Vikas,Gupta,39,7500000	
  
E4,Dinesh,Verma,32,2000000	
  
SM1,MM2,T3,E4	
  
Anuj,Anand,Vikas,Dinesh	
  
Sharma,,Gupta,Verma,	
  
45,34,39,32	
  
10000000,5000000,7500000,2000000	
  
RDBMS	
   Column-­‐oriented	
  
Oracle	
  RDBMS	
  Columnar	
  Expression	
  
Microso:	
  SQL	
  Server	
  2012	
  Enterprise	
  Edi6on	
  
Apache	
  Cassandra	
  
Hbase	
  
Google	
  BigTable	
  
Advantages	
  of	
  Colum-­‐oriented	
  
•  allow	
  adding	
  columns	
  over	
  6me	
  	
  
•  working	
  with	
  a	
  subset	
  of	
  the	
  available	
  
columns	
  	
  
•  new	
  values	
  are	
  applied	
  for	
  either	
  all	
  rows	
  at	
  
once	
  or	
  with	
  same-­‐	
  column	
  filters	
  	
  
•  efficient	
  storage	
  in	
  terms	
  of	
  size	
  	
  
Hoàng	
  Anh	
  Tú	
   19	
  
Document	
  Store	
  
Hoàng	
  Anh	
  Tú	
   20	
  
{	
  
	
  	
  	
  	
  	
  "EmployeeID":	
  "SM1",	
  
	
  	
  	
  	
  	
  "FirstName"	
  :	
  "Anuj",	
  
	
  	
  	
  	
  	
  "LastName"	
  	
  :	
  "Sharma",	
  
	
  	
  	
  	
  	
  "Age"	
  	
  	
  	
  	
  	
  	
  :	
  45,	
  
	
  	
  	
  	
  	
  "Salary"	
  	
  	
  	
  :	
  10000000	
  
}	
  
{	
  
	
  "EmployeeID":	
  "MM2",	
  
	
  "FirstName"	
  :	
  "Anand",	
  
	
  "Age”	
  :	
  34,	
  	
  
	
  "Salary”	
  :	
  5000000,	
  	
  
	
  "Address”:	
  {"Line1"	
  :	
  "123,	
  4th	
  Street",	
  	
  
	
   	
  "City"	
  :	
  "Bangalore",	
  	
  
	
   	
  "State"	
  :	
  "Karnataka"	
  },	
  	
  
	
  "Projects"	
  :	
  [	
  "nosql-­‐migra6on",	
  "top-­‐secret-­‐007"	
  ]	
  	
  
}	
  
	
  
XML	
  
JSON	
  
YAML	
  
1	
  
2	
  
MongoDB	
  
CouchDB	
  
Jackrabbit	
  
Lotus	
  Notes	
  
Apache	
  
Cassandra	
  
Terrastore	
  
Redis	
  
BaseX	
  
Advantages	
  of	
  Document	
  Store	
  
•  content	
  is	
  schemaless	
  	
  
•  may	
  or	
  may	
  not	
  be	
  possible	
  to	
  retrieve	
  or	
  
update	
  a	
  record	
  par6ally	
  	
  
•  Searching	
  across	
  mul6ple	
  en6ty	
  types	
  is	
  far	
  
more	
  trivial	
  	
  
•  JSON-­‐based	
  stores	
  are	
  easy	
  to	
  define	
  what	
  I	
  
call	
  projec8ons	
  	
  
Hoàng	
  Anh	
  Tú	
   21	
  
Key-­‐value	
  Store	
  
Hoàng	
  Anh	
  Tú	
   22	
  
Redis	
  (in-­‐memory,	
  with	
  dump	
  or	
  command-­‐log	
  
persistence)	
  
Memcached	
  (in-­‐memory)	
  
MemcacheDB	
  (built	
  on	
  Memcached)	
  
Berkley	
  DB	
  
Voldemort	
  (open	
  source	
  implementa6on	
  of	
  
Amazon	
  Dynamo)	
  
•  Unlike	
  a	
  document	
  store	
  that	
  can	
  create	
  a	
  key	
  when	
  a	
  
new	
  document	
  is	
  inserted,	
  a	
  key-­‐value	
  store	
  requires	
  the	
  
key	
  to	
  be	
  specified	
  	
  
•  Unlike	
  a	
  document	
  store	
  where	
  the	
  value	
  can	
  be	
  indexed	
  
and	
  queried,	
  for	
  a	
  key-­‐value	
  store,	
  the	
  value	
  is	
  opaque	
  
and	
  as	
  such,	
  the	
  key	
  must	
  be	
  known	
  to	
  retrieve	
  the	
  
value	
  
Advantages	
  of	
  Key-­‐value	
  Store	
  
•  op6mized	
  for	
  querying	
  against	
  keys	
  	
  
•  one	
  can	
  generate	
  the	
  keys	
  smartly—say,	
  
bucketed	
  UUID—and	
  can	
  query	
  against	
  ranges	
  
of	
  keys.	
  	
  
Hoàng	
  Anh	
  Tú	
   23	
  
Graph	
  
Hoàng	
  Anh	
  Tú	
   24	
  
Neo4j	
  
FlockDB	
  (from	
  Twijer)	
  
RethinkDB	
  
Advantages	
  of	
  Graph	
  Store	
  
•  special	
  purpose	
  NoSQL	
  databases	
  op6mized	
  
for	
  rela6on-­‐heavy	
  data	
  	
  
•  easy	
  representa6on,	
  retrieval	
  and	
  
manipula6on	
  of	
  rela6onships	
  between	
  the	
  
en66es	
  	
  
•  It	
  is	
  not	
  uncommon	
  to	
  store	
  data	
  in	
  a	
  
document	
  store	
  and	
  rela6onships	
  in	
  a	
  graph	
  
database.	
  	
  
Hoàng	
  Anh	
  Tú	
   25	
  
References	
  
•  Gexng	
  started	
  with	
  NoSQL,	
  Gaurav	
  Vaish,	
  
Packt	
  Publishing,	
  2013	
  
Hoàng	
  Anh	
  Tú	
   26	
  
 
What’s Your Message?
Thanks for your
attentation
Hoàng	
  Anh	
  Tú	
   27	
  

More Related Content

What's hot

2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング
2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング
2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニングkouji_s_0808
 
MariaDB Xpand 고객사례 안내.pdf
MariaDB Xpand 고객사례 안내.pdfMariaDB Xpand 고객사례 안내.pdf
MariaDB Xpand 고객사례 안내.pdfssusercbaa33
 
Troubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contentionTroubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contentionTanel Poder
 
「Oracle Database + Java + Linux」 環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1
「Oracle Database + Java + Linux」環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1「Oracle Database + Java + Linux」環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1
「Oracle Database + Java + Linux」 環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1Shogo Wakayama
 
NoSQL databases - An introduction
NoSQL databases - An introductionNoSQL databases - An introduction
NoSQL databases - An introductionPooyan Mehrparvar
 
Espresso: LinkedIn's Distributed Data Serving Platform (Paper)
Espresso: LinkedIn's Distributed Data Serving Platform (Paper)Espresso: LinkedIn's Distributed Data Serving Platform (Paper)
Espresso: LinkedIn's Distributed Data Serving Platform (Paper)Amy W. Tang
 
NoSQL Databases
NoSQL DatabasesNoSQL Databases
NoSQL DatabasesBADR
 
Espresso: LinkedIn's Distributed Data Serving Platform (Talk)
Espresso: LinkedIn's Distributed Data Serving Platform (Talk)Espresso: LinkedIn's Distributed Data Serving Platform (Talk)
Espresso: LinkedIn's Distributed Data Serving Platform (Talk)Amy W. Tang
 
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...Aaron Shilo
 
No SQL- The Future Of Data Storage
No SQL- The Future Of Data StorageNo SQL- The Future Of Data Storage
No SQL- The Future Of Data StorageBethmi Gunasekara
 
CockroachDB: Architecture of a Geo-Distributed SQL Database
CockroachDB: Architecture of a Geo-Distributed SQL DatabaseCockroachDB: Architecture of a Geo-Distributed SQL Database
CockroachDB: Architecture of a Geo-Distributed SQL DatabaseC4Media
 
Cassandra by example - the path of read and write requests
Cassandra by example - the path of read and write requestsCassandra by example - the path of read and write requests
Cassandra by example - the path of read and write requestsgrro
 
MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...
MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...
MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...dkalaev
 
İleri Seviye T-SQL Programlama - Chapter 18
İleri Seviye T-SQL Programlama - Chapter 18İleri Seviye T-SQL Programlama - Chapter 18
İleri Seviye T-SQL Programlama - Chapter 18Cihan Özhan
 
ここからはじめる SQL Server の状態取得
ここからはじめる SQL Server の状態取得ここからはじめる SQL Server の状態取得
ここからはじめる SQL Server の状態取得Masayuki Ozawa
 

What's hot (17)

2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング
2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング
2009.10.28 現場で役立つ oracle dbのパフォーマンスチューニング
 
MariaDB Xpand 고객사례 안내.pdf
MariaDB Xpand 고객사례 안내.pdfMariaDB Xpand 고객사례 안내.pdf
MariaDB Xpand 고객사례 안내.pdf
 
Troubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contentionTroubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contention
 
「Oracle Database + Java + Linux」 環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1
「Oracle Database + Java + Linux」環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1「Oracle Database + Java + Linux」環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1
「Oracle Database + Java + Linux」 環境における性能問題の調査手法 ~ミッションクリティカルシステムの現場から~ Part.1
 
NoSQL databases - An introduction
NoSQL databases - An introductionNoSQL databases - An introduction
NoSQL databases - An introduction
 
Espresso: LinkedIn's Distributed Data Serving Platform (Paper)
Espresso: LinkedIn's Distributed Data Serving Platform (Paper)Espresso: LinkedIn's Distributed Data Serving Platform (Paper)
Espresso: LinkedIn's Distributed Data Serving Platform (Paper)
 
NoSQL Databases
NoSQL DatabasesNoSQL Databases
NoSQL Databases
 
NOSQL vs SQL
NOSQL vs SQLNOSQL vs SQL
NOSQL vs SQL
 
Espresso: LinkedIn's Distributed Data Serving Platform (Talk)
Espresso: LinkedIn's Distributed Data Serving Platform (Talk)Espresso: LinkedIn's Distributed Data Serving Platform (Talk)
Espresso: LinkedIn's Distributed Data Serving Platform (Talk)
 
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
Exploring Oracle Database Performance Tuning Best Practices for DBAs and Deve...
 
No SQL- The Future Of Data Storage
No SQL- The Future Of Data StorageNo SQL- The Future Of Data Storage
No SQL- The Future Of Data Storage
 
NOSQL
NOSQLNOSQL
NOSQL
 
CockroachDB: Architecture of a Geo-Distributed SQL Database
CockroachDB: Architecture of a Geo-Distributed SQL DatabaseCockroachDB: Architecture of a Geo-Distributed SQL Database
CockroachDB: Architecture of a Geo-Distributed SQL Database
 
Cassandra by example - the path of read and write requests
Cassandra by example - the path of read and write requestsCassandra by example - the path of read and write requests
Cassandra by example - the path of read and write requests
 
MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...
MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...
MVP (минимальный жизнеспособный продукт): как не потерять деньги на разработк...
 
İleri Seviye T-SQL Programlama - Chapter 18
İleri Seviye T-SQL Programlama - Chapter 18İleri Seviye T-SQL Programlama - Chapter 18
İleri Seviye T-SQL Programlama - Chapter 18
 
ここからはじめる SQL Server の状態取得
ここからはじめる SQL Server の状態取得ここからはじめる SQL Server の状態取得
ここからはじめる SQL Server の状態取得
 

Similar to NoSQL Overview

Relational and non relational database 7
Relational and non relational database 7Relational and non relational database 7
Relational and non relational database 7abdulrahmanhelan
 
Nosql part1 8th December
Nosql part1 8th December Nosql part1 8th December
Nosql part1 8th December Ruru Chowdhury
 
NoSql Data Management
NoSql Data ManagementNoSql Data Management
NoSql Data Managementsameerfaizan
 
A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...
A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...
A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...Qian Lin
 
Agility and Scalability with MongoDB
Agility and Scalability with MongoDBAgility and Scalability with MongoDB
Agility and Scalability with MongoDBMongoDB
 
SQL Now! How Optiq brings the best of SQL to NoSQL data.
SQL Now! How Optiq brings the best of SQL to NoSQL data.SQL Now! How Optiq brings the best of SQL to NoSQL data.
SQL Now! How Optiq brings the best of SQL to NoSQL data.Julian Hyde
 
No sqlpresentation
No sqlpresentationNo sqlpresentation
No sqlpresentationSalma Gouia
 
Chapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choicesChapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choicesMaynooth University
 
Presentation on NoSQL Database related RDBMS
Presentation on NoSQL Database related RDBMSPresentation on NoSQL Database related RDBMS
Presentation on NoSQL Database related RDBMSabdurrobsoyon
 
NoSQL Intro with cassandra
NoSQL Intro with cassandraNoSQL Intro with cassandra
NoSQL Intro with cassandraBrian Enochson
 
Introduction to mongodb
Introduction to mongodbIntroduction to mongodb
Introduction to mongodbMohammed Ragab
 

Similar to NoSQL Overview (20)

No sq lv1_0
No sq lv1_0No sq lv1_0
No sq lv1_0
 
Relational and non relational database 7
Relational and non relational database 7Relational and non relational database 7
Relational and non relational database 7
 
NoSQL and MongoDB
NoSQL and MongoDBNoSQL and MongoDB
NoSQL and MongoDB
 
Nosql part1 8th December
Nosql part1 8th December Nosql part1 8th December
Nosql part1 8th December
 
NoSql Data Management
NoSql Data ManagementNoSql Data Management
NoSql Data Management
 
NoSQL
NoSQLNoSQL
NoSQL
 
Big data stores
Big data  storesBig data  stores
Big data stores
 
NoSQL.pptx
NoSQL.pptxNoSQL.pptx
NoSQL.pptx
 
the rising no sql technology
the rising no sql technologythe rising no sql technology
the rising no sql technology
 
6269441.ppt
6269441.ppt6269441.ppt
6269441.ppt
 
Cassandra training
Cassandra trainingCassandra training
Cassandra training
 
A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...
A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...
A Survey of Advanced Non-relational Database Systems: Approaches and Applicat...
 
Agility and Scalability with MongoDB
Agility and Scalability with MongoDBAgility and Scalability with MongoDB
Agility and Scalability with MongoDB
 
SQL Now! How Optiq brings the best of SQL to NoSQL data.
SQL Now! How Optiq brings the best of SQL to NoSQL data.SQL Now! How Optiq brings the best of SQL to NoSQL data.
SQL Now! How Optiq brings the best of SQL to NoSQL data.
 
No sqlpresentation
No sqlpresentationNo sqlpresentation
No sqlpresentation
 
NoSQL Consepts
NoSQL ConseptsNoSQL Consepts
NoSQL Consepts
 
Chapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choicesChapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choices
 
Presentation on NoSQL Database related RDBMS
Presentation on NoSQL Database related RDBMSPresentation on NoSQL Database related RDBMS
Presentation on NoSQL Database related RDBMS
 
NoSQL Intro with cassandra
NoSQL Intro with cassandraNoSQL Intro with cassandra
NoSQL Intro with cassandra
 
Introduction to mongodb
Introduction to mongodbIntroduction to mongodb
Introduction to mongodb
 

Recently uploaded

Halmar dropshipping via API with DroFx
Halmar  dropshipping  via API with DroFxHalmar  dropshipping  via API with DroFx
Halmar dropshipping via API with DroFxolyaivanovalion
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxStephen266013
 
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Callshivangimorya083
 
Generative AI on Enterprise Cloud with NiFi and Milvus
Generative AI on Enterprise Cloud with NiFi and MilvusGenerative AI on Enterprise Cloud with NiFi and Milvus
Generative AI on Enterprise Cloud with NiFi and MilvusTimothy Spann
 
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
 
Log Analysis using OSSEC sasoasasasas.pptx
Log Analysis using OSSEC sasoasasasas.pptxLog Analysis using OSSEC sasoasasasas.pptx
Log Analysis using OSSEC sasoasasasas.pptxJohnnyPlasten
 
VIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service Amravati
VIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service AmravatiVIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service Amravati
VIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service AmravatiSuhani Kapoor
 
Unveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data AnalystUnveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data AnalystSamantha Rae Coolbeth
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Smarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxSmarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxolyaivanovalion
 
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
 
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Callshivangimorya083
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfLars Albertsson
 
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiLow Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiSuhani Kapoor
 
Brighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingBrighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingNeil Barnes
 
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一ffjhghh
 
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
 
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...Suhani Kapoor
 

Recently uploaded (20)

Halmar dropshipping via API with DroFx
Halmar  dropshipping  via API with DroFxHalmar  dropshipping  via API with DroFx
Halmar dropshipping via API with DroFx
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docx
 
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
꧁❤ Aerocity Call Girls Service Aerocity Delhi ❤꧂ 9999965857 ☎️ Hard And Sexy ...
 
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls Punjabi Bagh 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
 
Generative AI on Enterprise Cloud with NiFi and Milvus
Generative AI on Enterprise Cloud with NiFi and MilvusGenerative AI on Enterprise Cloud with NiFi and Milvus
Generative AI on Enterprise Cloud with NiFi and Milvus
 
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
 
Log Analysis using OSSEC sasoasasasas.pptx
Log Analysis using OSSEC sasoasasasas.pptxLog Analysis using OSSEC sasoasasasas.pptx
Log Analysis using OSSEC sasoasasasas.pptx
 
VIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service Amravati
VIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service AmravatiVIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service Amravati
VIP Call Girls in Amravati Aarohi 8250192130 Independent Escort Service Amravati
 
Unveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data AnalystUnveiling Insights: The Role of a Data Analyst
Unveiling Insights: The Role of a Data Analyst
 
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Smarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxSmarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptx
 
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
 
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdf
 
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiLow Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
 
Brighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingBrighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data Storytelling
 
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一定制英国白金汉大学毕业证(UCB毕业证书)																			成绩单原版一比一
定制英国白金汉大学毕业证(UCB毕业证书) 成绩单原版一比一
 
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
 
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
 

NoSQL Overview

  • 1. Hoàng  Anh  Tú   NoSQL Introduction to NoSQL Hoàng  Anh  Tú   1  
  • 2. Introduc6on    to  NoSQL                                                       1An  Overview   of  NoSQL                                                   2Characteris8cs   of  NoSQL                                               3NoSQL  Storage   Types                  
  • 3.                                                                     1 AN  OVERVIEW  OF  NOSQL     Hoàng  Anh  Tú   3  
  • 4. What  is  NoSQL?   Hoàng  Anh  Tú   4   A  NoSQL  (o:en  interpreted  as  Not  Only  SQL)   database  provides  a  mechanism  for  storage  and   retrieval  of  data  that  is  modeled  in  means  other   than  the  tabular  rela6ons  used  in  rela6onal   databases.  
  • 5. History   Hoàng  Anh  Tú   5   Billions  of  requests  a  month   RDBMS  limits:   -­‐  scalability   -­‐  paralleliza6on     -­‐  cost     the  data  set  is  minimally  cross-­‐referenced   GFS   Chubby  MapReduce   Big  Table   Lucene   Hadoop   Cassandra   Pig   2003   2006  2004  1999   2005   2008  
  • 6. CAP  Theorem   Hoàng  Anh  Tú   6   all  nodes  see  the  same   data  at  the  same  6me   A  non-­‐failing  node  will   return  a  reasonable   response  within  a   reasonable  amount  of  6me   (no  error  or  6meout)   The  system  will  con6nue  to   func6on  when  network   par66ons  occur  
  • 7. CP  vs  AP   Hoàng  Anh  Tú   7   Consistency/Par66on  Tolerance   Availability/Par66on  Tolerance  
  • 8. ACID  vs  BASE   •  Basic  availability:  Each  request  is  guaranteed   a  response—successful  or  failed  execu6on.     •  SoL  state:  The  state  of  the  system  may   change  over  6me,  at  6mes  without  any  input   (for  eventual  consistency).     •  Eventual  consistency:  The  database  may  be   momentarily  inconsistent  but  will  be   consistent  eventually.     Hoàng  Anh  Tú   8  
  • 9. Why  NoSQL?   •  Schemaless  data  representa8on     •  Development  8me   •  Speed     •  Plan  ahead  for  scalability     Hoàng  Anh  Tú   9  
  • 10. List  of  NoSQL  Databases   Hoàng  Anh  Tú   10  
  • 11.                                                                     2 CHARACTERISTICS  OF  NOSQL   Hoàng  Anh  Tú   11  
  • 12. Applica8on   Hoàng  Anh  Tú   12  
  • 13. RDBMS  Approach   •  Iden8fy  actors     •  Define  models     •  Define  en88es     •  Define  rela8onships     •  Program  database  and  applica8on     •  Iterate     Hoàng  Anh  Tú   13  
  • 14. En8ty  Rela8onship  Diagram   Hoàng  Anh  Tú   14  
  • 15. Challenges   •  Schema  flexibility:  the  schema  is  needed  before  implemen6ng  the   applica6on.  Upda6ng  schema  is  hard  especially  when  edi6ng  the  exis6ng   tables’  schema.   •  Complex  queries:  the  tables  are  designed  denormalized  which  means  that   the  developers  end  up  wri6ng  complex  so-­‐called  JOIN  queries     •  Data  update:  Upda6ng  data  across  tables  is  probably  one  of  the  more   complex  scenarios  especially  if  they  are  to  be  a  part  of  the  transac6on.   Note  that  keeping  the  transac6on  open  for  a  long  dura6on  hampers  the   performance     •  Scalability     –  What  is  the  6me  taken  to  synchronize  the  data  across  physical  database   instances?     –  What  is  the  6me  taken  to  synchronize  the  data  across  datacenters?     –  What  is  the  bandwidth  requirement  to  synchronize  data?  Is  the  data   exchanged  op6mized?     –   What  is  the  latency  when  any  update  is  synchronized  across  servers?   Typically,  the  records  will  be  locked  during  an  update.     Hoàng  Anh  Tú   15  
  • 16. NoSQL  Approach   •  Schema  flexibility:  allows  flexibility  of  adding  one   or  more  columns  as  required,  on  the  fly       •  Complex  queries:  NoSQL  databases  do  not  have   support  for  rela6onships  or  foreign  keys     •  Data  update:  synchroniza6on  with  conflict   resolu6on  and  eventually,  consistency  across  the   datacenters  within  an  acceptable  6me  that  would   run  in  few  milliseconds     •  Scalability   –  Neilix  moved  from  Oracle  RDBMS  to  Apache   Cassandra,  and  they  could  achieve  over  a  million   writes  per  second1.     Hoàng  Anh  Tú   16   1hjp://www.slideshare.net/hluu/neilix-­‐  moving-­‐to-­‐cloud  
  • 17.                                                                     3 NOSQL  STORAGE  TYPES   Hoàng  Anh  Tú   17  
  • 18. Column-­‐oriented   Hoàng  Anh  Tú   18   SM1,Anuj,Sharma,45,10000000   MM2,Anand,,34,5000000   T3,Vikas,Gupta,39,7500000   E4,Dinesh,Verma,32,2000000   SM1,MM2,T3,E4   Anuj,Anand,Vikas,Dinesh   Sharma,,Gupta,Verma,   45,34,39,32   10000000,5000000,7500000,2000000   RDBMS   Column-­‐oriented   Oracle  RDBMS  Columnar  Expression   Microso:  SQL  Server  2012  Enterprise  Edi6on   Apache  Cassandra   Hbase   Google  BigTable  
  • 19. Advantages  of  Colum-­‐oriented   •  allow  adding  columns  over  6me     •  working  with  a  subset  of  the  available   columns     •  new  values  are  applied  for  either  all  rows  at   once  or  with  same-­‐  column  filters     •  efficient  storage  in  terms  of  size     Hoàng  Anh  Tú   19  
  • 20. Document  Store   Hoàng  Anh  Tú   20   {            "EmployeeID":  "SM1",            "FirstName"  :  "Anuj",            "LastName"    :  "Sharma",            "Age"              :  45,            "Salary"        :  10000000   }   {    "EmployeeID":  "MM2",    "FirstName"  :  "Anand",    "Age”  :  34,      "Salary”  :  5000000,      "Address”:  {"Line1"  :  "123,  4th  Street",        "City"  :  "Bangalore",        "State"  :  "Karnataka"  },      "Projects"  :  [  "nosql-­‐migra6on",  "top-­‐secret-­‐007"  ]     }     XML   JSON   YAML   1   2   MongoDB   CouchDB   Jackrabbit   Lotus  Notes   Apache   Cassandra   Terrastore   Redis   BaseX  
  • 21. Advantages  of  Document  Store   •  content  is  schemaless     •  may  or  may  not  be  possible  to  retrieve  or   update  a  record  par6ally     •  Searching  across  mul6ple  en6ty  types  is  far   more  trivial     •  JSON-­‐based  stores  are  easy  to  define  what  I   call  projec8ons     Hoàng  Anh  Tú   21  
  • 22. Key-­‐value  Store   Hoàng  Anh  Tú   22   Redis  (in-­‐memory,  with  dump  or  command-­‐log   persistence)   Memcached  (in-­‐memory)   MemcacheDB  (built  on  Memcached)   Berkley  DB   Voldemort  (open  source  implementa6on  of   Amazon  Dynamo)   •  Unlike  a  document  store  that  can  create  a  key  when  a   new  document  is  inserted,  a  key-­‐value  store  requires  the   key  to  be  specified     •  Unlike  a  document  store  where  the  value  can  be  indexed   and  queried,  for  a  key-­‐value  store,  the  value  is  opaque   and  as  such,  the  key  must  be  known  to  retrieve  the   value  
  • 23. Advantages  of  Key-­‐value  Store   •  op6mized  for  querying  against  keys     •  one  can  generate  the  keys  smartly—say,   bucketed  UUID—and  can  query  against  ranges   of  keys.     Hoàng  Anh  Tú   23  
  • 24. Graph   Hoàng  Anh  Tú   24   Neo4j   FlockDB  (from  Twijer)   RethinkDB  
  • 25. Advantages  of  Graph  Store   •  special  purpose  NoSQL  databases  op6mized   for  rela6on-­‐heavy  data     •  easy  representa6on,  retrieval  and   manipula6on  of  rela6onships  between  the   en66es     •  It  is  not  uncommon  to  store  data  in  a   document  store  and  rela6onships  in  a  graph   database.     Hoàng  Anh  Tú   25  
  • 26. References   •  Gexng  started  with  NoSQL,  Gaurav  Vaish,   Packt  Publishing,  2013   Hoàng  Anh  Tú   26  
  • 27.   What’s Your Message? Thanks for your attentation Hoàng  Anh  Tú   27