<s>
A	O
NoSQL	O
(	O
originally	O
referring	O
to	O
"	O
non-SQL	O
"	O
or	O
"	O
non-relational	O
"	O
)	O
database	O
provides	O
a	O
mechanism	O
for	O
storage	B-General_Concept
and	O
retrieval	B-Application
of	O
data	O
that	O
is	O
modeled	O
in	O
means	O
other	O
than	O
the	O
tabular	O
relations	O
used	O
in	O
relational	B-Application
databases	I-Application
.	O
</s>
<s>
NoSQL	O
databases	O
are	O
increasingly	O
used	O
in	O
big	B-Application
data	I-Application
and	O
real-time	B-Application
web	I-Application
applications	O
.	O
</s>
<s>
NoSQL	O
systems	O
are	O
also	O
sometimes	O
called	O
Not	O
only	O
SQL	B-Language
to	O
emphasize	O
that	O
they	O
may	O
support	O
SQL-like	O
query	B-Language
languages	O
or	O
sit	O
alongside	O
SQL	B-Language
databases	I-Language
in	O
polyglot-persistent	B-General_Concept
architectures	O
.	O
</s>
<s>
Motivations	O
for	O
this	O
approach	O
include	O
simplicity	O
of	O
design	O
,	O
simpler	O
"	O
horizontal	O
"	O
scaling	O
to	O
clusters	B-Architecture
of	I-Architecture
machines	I-Architecture
(	O
which	O
is	O
a	O
problem	O
for	O
relational	B-Application
databases	I-Application
)	O
,	O
finer	O
control	O
over	O
availability	O
and	O
limiting	O
the	O
object-relational	B-Architecture
impedance	I-Architecture
mismatch	I-Architecture
.	O
</s>
<s>
key	B-Data_Structure
–	I-Data_Structure
value	I-Data_Structure
pair	I-Data_Structure
,	O
wide	B-Application
column	I-Application
,	O
graph	B-Application
,	O
or	O
document	B-General_Concept
)	O
are	O
different	O
from	O
those	O
used	O
by	O
default	O
in	O
relational	B-Application
databases	I-Application
,	O
making	O
some	O
operations	O
faster	O
in	O
NoSQL	O
.	O
</s>
<s>
Sometimes	O
the	O
data	O
structures	O
used	O
by	O
NoSQL	O
databases	O
are	O
also	O
viewed	O
as	O
"	O
more	O
flexible	O
"	O
than	O
relational	B-Application
database	I-Application
tables	O
.	O
</s>
<s>
Many	O
NoSQL	O
stores	O
compromise	O
consistency	O
(	O
in	O
the	O
sense	O
of	O
the	O
CAP	B-Operating_System
theorem	I-Operating_System
)	O
in	O
favor	O
of	O
availability	O
,	O
partition	O
tolerance	O
,	O
and	O
speed	O
.	O
</s>
<s>
Barriers	O
to	O
the	O
greater	O
adoption	O
of	O
NoSQL	O
stores	O
include	O
the	O
use	O
of	O
low-level	O
query	B-Language
languages	O
(	O
instead	O
of	O
SQL	B-Language
,	O
for	O
instance	O
)	O
,	O
lack	O
of	O
ability	O
to	O
perform	O
ad	O
hoc	O
joins	B-Language
across	O
tables	O
,	O
lack	O
of	O
standardized	O
interfaces	O
,	O
and	O
huge	O
previous	O
investments	O
in	O
existing	O
relational	B-Application
databases	I-Application
.	O
</s>
<s>
Instead	O
,	O
most	O
NoSQL	O
databases	O
offer	O
a	O
concept	O
of	O
"	O
eventual	B-General_Concept
consistency	I-General_Concept
"	O
,	O
in	O
which	O
database	O
changes	O
are	O
propagated	O
to	O
all	O
nodes	O
"	O
eventually	O
"	O
(	O
typically	O
within	O
milliseconds	O
)	O
,	O
so	O
queries	B-Language
for	O
data	O
might	O
not	O
return	O
updated	O
data	O
immediately	O
or	O
might	O
result	O
in	O
reading	O
data	O
that	O
is	O
not	O
accurate	O
,	O
a	O
problem	O
known	O
as	O
stale	O
read	O
.	O
</s>
<s>
Additionally	O
,	O
some	O
NoSQL	O
systems	O
may	O
exhibit	O
lost	O
writes	O
and	O
other	O
forms	O
of	O
data	B-General_Concept
loss	I-General_Concept
.	O
</s>
<s>
Some	O
NoSQL	O
systems	O
provide	O
concepts	O
such	O
as	O
write-ahead	B-Algorithm
logging	I-Algorithm
to	O
avoid	O
data	B-General_Concept
loss	I-General_Concept
.	O
</s>
<s>
For	O
distributed	B-General_Concept
transaction	I-General_Concept
processing	I-General_Concept
across	O
multiple	O
databases	O
,	O
data	O
consistency	O
is	O
an	O
even	O
bigger	O
challenge	O
that	O
is	O
difficult	O
for	O
both	O
NoSQL	O
and	O
relational	B-Application
databases	I-Application
.	O
</s>
<s>
Relational	B-Application
databases	I-Application
"	O
do	O
not	O
allow	O
referential	O
integrity	O
constraints	O
to	O
span	O
databases	O
"	O
.	O
</s>
<s>
Few	O
systems	O
maintain	O
both	O
ACID	O
transactions	O
and	O
X/Open	O
XA	O
standards	O
for	O
distributed	B-General_Concept
transaction	I-General_Concept
processing	I-General_Concept
.	O
</s>
<s>
Interactive	O
relational	B-Application
databases	I-Application
share	O
conformational	O
relay	O
analysis	O
techniques	O
as	O
a	O
common	O
feature	O
.	O
</s>
<s>
The	O
term	O
NoSQL	O
was	O
used	O
by	O
Carlo	O
Strozzi	O
in	O
1998	O
to	O
name	O
his	O
lightweight	O
Strozzi	B-Application
NoSQL	I-Application
open-source	I-Application
relational	I-Application
database	I-Application
that	O
did	O
not	O
expose	O
the	O
standard	O
Structured	B-Language
Query	I-Language
Language	I-Language
(	O
SQL	B-Language
)	O
interface	O
,	O
but	O
was	O
still	O
relational	O
.	O
</s>
<s>
Johan	O
Oskarsson	O
,	O
then	O
a	O
developer	O
at	O
Last.fm,	O
reintroduced	O
the	O
term	O
NoSQL	O
in	O
early	O
2009	O
when	O
he	O
organized	O
an	O
event	O
to	O
discuss	O
"	O
open-source	O
distributed	B-Operating_System
,	I-Operating_System
non-relational	I-Operating_System
databases	I-Operating_System
"	O
.	O
</s>
<s>
The	O
name	O
attempted	O
to	O
label	O
the	O
emergence	O
of	O
an	O
increasing	O
number	O
of	O
non-relational	O
,	O
distributed	O
data	O
stores	O
,	O
including	O
open	O
source	O
clones	O
of	O
Google	O
's	O
Bigtable/MapReduce	O
and	O
Amazon	O
's	O
DynamoDB	B-Application
.	O
</s>
<s>
Key	O
–	O
value	O
(	O
KV	O
)	O
stores	O
use	O
the	O
associative	B-Application
array	I-Application
(	O
also	O
called	O
a	O
map	O
or	O
dictionary	B-Application
)	O
as	O
their	O
fundamental	O
data	O
model	O
.	O
</s>
<s>
Key	B-Data_Structure
–	I-Data_Structure
value	I-Data_Structure
stores	I-Data_Structure
can	O
use	O
consistency	B-General_Concept
models	I-General_Concept
ranging	O
from	O
eventual	B-General_Concept
consistency	I-General_Concept
to	O
serializability	B-Operating_System
.	O
</s>
<s>
There	O
are	O
various	O
hardware	O
implementations	O
,	O
and	O
some	O
users	O
store	O
data	O
in	O
memory	O
(	O
RAM	O
)	O
,	O
while	O
others	O
on	O
solid-state	B-Device
drives	I-Device
(	O
SSD	B-Device
)	O
or	O
rotating	B-Device
disks	I-Device
(	O
aka	O
hard	B-Device
disk	I-Device
drive	I-Device
(	O
HDD	O
)	O
)	O
.	O
</s>
<s>
The	O
central	O
concept	O
of	O
a	O
document	B-General_Concept
store	I-General_Concept
is	O
that	O
of	O
a	O
"	O
document	B-General_Concept
"	O
.	O
</s>
<s>
While	O
the	O
details	O
of	O
this	O
definition	O
differ	O
among	O
document-oriented	B-General_Concept
databases	I-General_Concept
,	O
they	O
all	O
assume	O
that	O
documents	O
encapsulate	O
and	O
encode	O
data	O
(	O
or	O
information	O
)	O
in	O
some	O
standard	O
formats	O
or	O
encodings	O
.	O
</s>
<s>
Encodings	O
in	O
use	O
include	O
XML	B-Protocol
,	O
YAML	B-Protocol
,	O
and	O
JSON	B-General_Concept
and	O
binary	O
forms	O
like	O
BSON	B-Protocol
.	O
</s>
<s>
Documents	O
are	O
addressed	O
in	O
the	O
database	O
via	O
a	O
unique	O
key	O
that	O
represents	O
that	O
document	B-General_Concept
.	O
</s>
<s>
Another	O
defining	O
characteristic	O
of	O
a	O
document-oriented	B-General_Concept
database	I-General_Concept
is	O
an	O
API	O
or	O
query	B-Language
language	O
to	O
retrieve	O
documents	O
based	O
on	O
their	O
contents	O
.	O
</s>
<s>
Compared	O
to	O
relational	B-Application
databases	I-Application
,	O
collections	O
could	O
be	O
considered	O
analogous	O
to	O
tables	O
and	O
documents	O
analogous	O
to	O
records	O
.	O
</s>
<s>
Graph	B-Application
databases	I-Application
are	O
designed	O
for	O
data	O
whose	O
relations	O
are	O
well	O
represented	O
as	O
a	O
graph	B-Application
consisting	O
of	O
elements	O
connected	O
by	O
a	O
finite	O
number	O
of	O
relations	O
.	O
</s>
<s>
Performance	O
and	O
scalability	O
comparisons	O
are	O
most	O
commonly	O
done	O
using	O
the	O
YCSB	B-Application
benchmark	O
.	O
</s>
<s>
Since	O
most	O
NoSQL	O
databases	O
lack	O
ability	O
for	O
joins	B-Language
in	O
queries	B-Language
,	O
the	O
database	B-Application
schema	I-Application
generally	O
needs	O
to	O
be	O
designed	O
differently	O
.	O
</s>
<s>
(	O
See	O
table	B-Language
Join	I-Language
and	O
ACID	O
Support	O
for	O
NoSQL	O
databases	O
that	O
support	O
joins	B-Language
.	O
)	O
</s>
<s>
Instead	O
of	O
retrieving	O
all	O
the	O
data	O
with	O
one	O
query	B-Language
,	O
it	O
is	O
common	O
to	O
do	O
several	O
queries	B-Language
to	O
get	O
the	O
desired	O
data	O
.	O
</s>
<s>
NoSQL	O
queries	B-Language
are	O
often	O
faster	O
than	O
traditional	O
SQL	B-Language
queries	B-Language
so	O
the	O
cost	O
of	O
additional	O
queries	B-Language
may	O
be	O
acceptable	O
.	O
</s>
<s>
If	O
an	O
excessive	O
number	O
of	O
queries	B-Language
would	O
be	O
necessary	O
,	O
one	O
of	O
the	O
other	O
two	O
approaches	O
is	O
more	O
appropriate	O
.	O
</s>
<s>
With	O
document	B-General_Concept
databases	I-General_Concept
like	O
MongoDB	B-Application
it	O
is	O
common	O
to	O
put	O
more	O
data	O
in	O
a	O
smaller	O
number	O
of	O
collections	O
.	O
</s>
<s>
For	O
example	O
,	O
in	O
a	O
blogging	O
application	O
,	O
one	O
might	O
choose	O
to	O
store	O
comments	O
within	O
the	O
blog	O
post	O
document	B-General_Concept
so	O
that	O
with	O
a	O
single	O
retrieval	B-Application
one	O
gets	O
all	O
the	O
comments	O
.	O
</s>
<s>
Thus	O
in	O
this	O
approach	O
a	O
single	O
document	B-General_Concept
contains	O
all	O
the	O
data	O
you	O
need	O
for	O
a	O
specific	O
task	O
.	O
</s>
<s>
A	O
database	O
is	O
marked	O
as	O
supporting	O
ACID	O
properties	O
(	O
Atomicity	O
,	O
Consistency	O
,	O
Isolation	O
,	O
Durability	O
)	O
or	O
join	B-Language
operations	O
if	O
the	O
documentation	O
for	O
the	O
database	O
makes	O
that	O
claim	O
.	O
</s>
<s>
However	O
,	O
this	O
does	O
n't	O
necessarily	O
mean	O
that	O
the	O
capability	O
is	O
fully	O
supported	O
in	O
a	O
manner	O
similar	O
to	O
most	O
SQL	B-Language
databases	I-Language
.	O
</s>
