Oracle NoSQL Database Technical Introduction Presentation

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 34

1Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database Technical Introduction


Apostolos Giannakidis oft!are "#ality $ngineer
%#&lin 'o "( )eet#p *C#&e + %ece,&er 1-, 2013

2Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Safe Harbor
*he follo!ing is intended to provide an introd#ction to the Oracle 'o "( data&ase. .t is intended for infor,ation p#rposes only, and ,ay not &e incorporated into any contract. .t is not a co,,it,ent to deliver any ,aterial, code, or f#nctionality and sho#ld not &e relied #pon in f#nctionality, and sho#ld not &e relied #pon in ,aking p#rchasing decisions. *he develop,ent, release, and ti,ing of any feat#res or f#nctionality descri&ed for Oracle/s prod#cts re,ains at the sole discretion of Oracle.

3Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Disclaimer

Any vie!s e1pressed in this presentation are ,y o!n and do not necessarily reflect the vie!s of Oracle. *his presentation !ill not disc#ss prod#ct2s road ,ap as . do not represent the Oracle 'o "( data&ase develop,ent tea,. o,e slides and presentation ,aterial have &een re#sed fro, p#&licly availa&le presentations of %ave eglea#, Charles (a,& and A&hi %#&ey. )ost of the re#sed slides have &een edited &y ,e in order to #pdate the, or c#sto,i3e the, according to this presentation2s foc#s.

0Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Agenda
Oracle NoSQL Database Introduction Oracle 'o "( %ata&ase Architect#re Oracle 'o "( %ata&ase Operations 5 A6. "5A

4Copyright 2013, Oracle and/or its affiliates. All rights reserved.

What is Oracle NoSQL Database (ONDB


!nter"rise#class Distributed $e%#&alue store
7igh availa&ility )#lti8*9s to 69s capacity i,ple data ,odel *ransparent sharding *ransparent load &alancing $lastic scala&ility 6redicta&le perfor,ance AC.% transactions 'o8 ingle 6oint of :ail#re i,ple ad,inistration

-Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL DB Building Bloc's


Oracle Ber'ele% DB (a)a !dition
<o&#st and relia&le storage engine for a distri&#ted key/val#e %ata&ase

AC.% transactions 7igh availa&ility 7igh thro#ghp#t i,ple ad,inistration A,a3on %yna,o =olde,ort >(inkedin? Genie%9

Already proven in

;Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Building u"on Ber'ele% DB (a)a !dition
%yna,ic 6artitioning >aka (oad &alancing 6redicta&le latency )#lti8'ode &ack#p )onitoring )aBor/)inor key paradig, >!ith <)C capa&ilities

harding?

.ntelligent ro#ting of reA#ests

tring keys?

@Copyright 2013, Oracle and/or its affiliates. All rights reserved.

*om"atibilit%

#pported O 8 (in#1 and olaris 10

6#re i,ple,entation in Eava Eava and C A6.s 9indings availa&le for Eython, Er#&y,

CloB#re, Groovy, <hino

DCopyright 2013, Oracle and/or its affiliates. All rights reserved.

!nter"rise Integration + !,tensions

.ntegration !ith Oracle %ata&ase 8 $1ternal *a&les <%: Graph for 'o "( 8 #pport for 6A<"( .ntegration !ith )iddle!are

Oracle Coherence Oracle $vent 6rocessing

.ntegration !ithF

Apache 7adoop Apache Avro

10Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL DB )ersions

Oracle 'o "( %9 Co,,#nity $dition >AG6( v3?

O"en Source

Oracle 'o "( $nterprise $dition

$1tra feat#res for enterprise #se >$1ternal *a&les, <%:/ 6A<"(, O$6, Coherence, E)G, ')6? $nterprise #pport

Oracle 'o "( %9 Client %river #nder the Apache 2.0 (icense # Ne-

11Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Agenda
Oracle 'o "( %ata&ase .ntrod#ction Oracle NoSQL Database Architecture Oracle 'o "( %ata&ase Operations 5 A6. "5A

12Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Data .odel

)ap of Heys to =al#es )aBor / )inor Hey paradig, Heys are Eava trings

:#ll Hey I )aBor Hey 6ath J )inor Hey 6ath One or ,ore .a/or $e% co,ponents Kero or ,ore .inor $e% co,ponents

&alue field

=al#es are stored as ar&itrary &yte arrays >opaA#e val#es? =al#es can &e stored in A)ro for,at >reco,,ended? =al#es co#ld &e as si,ple or as co,ple1 the developer !ants

eriali3ation and %eseriali3ation is left #p to the application (arge O&Bect s#pport

'o restriction on si3e of the =al#e

13Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Data .odel

0ull $e% re"resentation format1

/)aBorCo,ponent1/)aBorCo,ponent2/8/)inorCo,ponent1/)inorCo,ponent2/

10Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Storage Terminolog%

Storage Nodes are physical >or virt#al? ,achines !ith their o!n local storage $very torage 'ode hosts one or ,ore 2e"lication Nodes

9y defa#lt, <eplication 'odes are 1F1 !ith torage 'odes

<eplication 'odes are organi3ed into 2e"lication 3rou"s >aka shards?

One of the <eplication 'odes is elected to &e the shard2s .aster node

'#,&er of nodes &elonging to a shard is called its 2e"lication 0actor $&Store is a collection of torage 'odes

14Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Storage 0undamentals

%ata is spread evenly across all the shards in #se &y the H= tore All Hey =al#e pairs !ith the sa,e )aBor Hey 6ath are cl#stered on the sa,e shard et of <eplication 'odes for each shard providesF

7igh Availa&ility <ead cala&ility

Crite operations on the Laster <eplication 'ode <ead operations on any <eplication 'ode

1-Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + Logical Architecture


$lastic hards >split, add, re,ove?
hard 1
Application 'o "( %9 %river

Replication Nodes

hard 2

hard '

Crites

)aster

)aster

)aster

<eads

<eplicas
1;Copyright 2013, Oracle and/or its affiliates. All rights reserved.

<eplicas

<eplicas

0eatures # 2e"lication

7igh availa&ility 7igh read thro#ghp#t

ingle8,aster ,#lti8replica replication strategy One or ,ore read8only replicas Mses *C6/.6 and standard Eava li&raries <esilient to partition ,aster fail#res #pports 7eterogeneo#s platfor, hard!are/O /E=) 6rovides linear scale o#t for read ops/sec

1@Copyright 2013, Oracle and/or its affiliates. All rights reserved.

0eatures + Trans"arent Load Balancing

<eads fro, ,aster or replicas Crites are evenly distri&#ted across shards .ntelligent Client %river is net!ork topology and latency a!are

<o#tes operations to the proper node 6erfor,s load &alancing <#n operations on fastest appropriate node ingle net!ork hop e1cept !hen node fails or topology changes *opology changes ret#rned !ith res#lts

1DCopyright 2013, Oracle and/or its affiliates. All rights reserved.

!)entual *onsistenc% and Data &ersioning


*onsistenc% 0undamentals
*here is an #n&o#nded delay in propagating !rite ops ,ade on

the )aster 'ode to all the other <eplication 'odes of the shard )aster node N ,ost #p8to8date data <eplicas N possi&ly slightly older versions >event#al consistency? yste, records version n#,&ers for key/val#e pairs, &#t ,aintains the single latest version in the store. 'o need for version reconciliation at the application level

20Copyright 2013, Oracle and/or its affiliates. All rights reserved.

0eatures + *onfigurable A*ID Transactions


3reater 0le,ibilit%

Config#ra&le %#ra&ility per op

everal d#ra&ility policies

Config#ra&le Consistency per op

everal consistency policies

eA#ence of operations as a single ato,ic #nit

<ecords ,#st share sa,e )aBor key

AC.% &y defa#lt *ransaction scope is single A6. call

21Copyright 2013, Oracle and/or its affiliates. All rights reserved.

$&Lite
Quic' de"lo%ment for de)elo"ers

i,plified version of Oracle 'o "( %ata&ase server ingle8node single8shard store >no replication? .ntended for #se &y application developers $1plore O'%9 A6.

Mnit *est applications

'ot for prod#ction deploy,ents or &ench,arking

22Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Agenda
Oracle 'o "( %ata&ase .ntrod#ction Oracle 'o "( %ata&ase Architect#re Oracle NoSQL Database O"erations 4 A5I "5A

23Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


Basic o"erations

%ata is accessed #sing )aBor and >optionally? )inor keys

*his ena&les O,#ltiP operations

C<M% operations

<ead / .nsert / Mpdate / %elete ingle and ,#lti8record operations AC.% transactions Co,pare And et Operations ><)C?

20Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


Basic o"erations (cont6d
.teration

Mnordered iteration across keys Ordered iteration across s#& keys !ithin a key <ange scans and f#ll key space scans

24Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


*27D A5I

put(Key, Value, [Durability, timeout]) putIfAbsent(K, V, [Durability, timeout]) putIfPresent(K, V, [Durability, timeout]) putIfVersion(K, V, Version, [Durability, timeout]) get(Key, [Consistency, timeout]) delete(Key, [Durability, timeout]) deleteIfVersion(Key, Version, [Durability, timeout])

2-Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


Iteration O"erations A5I

multiGetIterator(Direction, int batchSize, Key parentKey, KeyRange, Depth) Iterator<KeyValueVersion>

storeIterator(Direction direction, int batchSize [Key parentKey, KeyRange, Depth]) Iterator<KeyValueVersion>

2;Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


Bul' O"erations A5I

public inter ace OperationFactory

createPut, createPutIfPresent, createDelete, etc

Operation

execute(!ist"#peration$ operations) List<OperationResult>

2@Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


$e%2ange 8.ulti9 O"erations A5I

multiGet(Key parentKey, KeyRange, Depth, [Consistency, timeout]) SortedMap<Key,ValueVersion>

multiDelete(Key parentKey, KeyRange subRange, Depth, [Durability, timeout]) int

2DCopyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database + O"erations 4 A5I


$e% management A5I

create ey(!ist"String$ ma%or&ath) create ey(!ist"String$ ma%or&ath, !ist"String$ minor&ath) create ey(!ist"String$ ma%or&ath, String minorComponent) create ey(String ma%orComponent) from!tring(String pathString) ey

30Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Where do I go for more information:

Getting tarted !ith Oracle 'o "( %ata&ase Oracle 'o "( %ata&ase Availa&ility and :ailover Ad,inistrator2s G#ide Oracle *echnology 'et!ork

6rod#ct Overvie!s Chite 6apers / 6resentations Online *#torials / =ideos Online Ce&inars

31Copyright 2013, Oracle and/or its affiliates. All rights reserved.

Oracle NoSQL Database


Q4A

lides availa&le at !!!.giannakidis.info


32Copyright 2013, Oracle and/or its affiliates. All rights reserved.

33Copyright 2013, Oracle and/or its affiliates. All rights reserved.

30Copyright 2013, Oracle and/or its affiliates. All rights reserved.

You might also like