SlideShare une entreprise Scribd logo
1  sur  18
Télécharger pour lire hors ligne
Introduction to Terrastore Sven Johansson Mejsla @svjson Mats Henricson Crisp @matshenricson
NoSQL - A loosely defined movement - A complement to relational databases - Usually schema-less - Typically not concerned with transactions, locks or data integrity... - ...but more so with performance and scalability
Document-oriented databases - Advanced Key/Value stores - Documents are nested data structures – JSON or JSON-variants - Examples of implementations: ,[object Object]
MongoDB  (C++)
RavenDB  (C#)
Terrastore  (Java)
Terrastore - Open source project founded in Sept-Oct 2009 - Written entirely in Java - Based on Terracotta - Offers per-document consistency - Distributed - Elastic - Scalable at the computational level - Extensible
A Terrastore document { 'name' :  'Sven Johansson', 'age' :  '29', 'titles' : [   'Developer',   'Consultant',   'Destroyer of worlds', ], 'currentlyReading : { title: 'The book of Dave' author: 'Will Self'   } 'favouriteBooks' : [{ title: 'The naked and the dead', author: 'Norman Mailer'   },   { title: 'On the road', author: 'Jack Kerouac'   }] }
public class Person { private String name; private int age; private String[] titles; private Book currentlyReading; private List<Book> favouriteBooks; ... } ...and a corresponding Java Object
Deployment architecture Single cluster - 1 Master -  n  Servers ( n  hot standbys)
Deployment architecture Multi-cluster (Ensemble) - Cluster of  n  Masters -  n  Servers each
CRUD with Terrastore Mats Henricson Crisp AB Stockholm 2010-09-14, WTFPL license
Example public class Customer { private String name; private Address address; private List<PhoneNumber> phoneNumbers = new LinkedList<PhoneNumber>(); // ... } public class Address { private String street; // ... } public class PhoneNumber { private String number; private String type; // … } } Stockholm 2010-09-14, WTFPL license
Annotations? Base classes? Nope. The POJO:s are plain vanilla vanilla POJO:s Stockholm 2010-09-14, WTFPL license
You store your domain objects into different buckets. Examples: Buckets are identified by string names, such as &quot;customers&quot;, &quot;items&quot;, &quot;orders&quot;. Buckets are comparable to RDBMS tables, but with no schema! If you need to link objects in different buckets, Then you have to use domain unique IDs. Buckets ,[object Object]
One bucket for item data
One bucket for orders Stockholm 2010-09-14, WTFPL license
First we need a terrastore client That localhost URL points to a terrastore  server . If that server goes down, then your client is toast. Next version of the API have implemented fallbacks. Enough! I want an example, now! TerrastoreClient client = new TerrastoreClient(&quot;http://localhost:8080&quot;, new HTTPConnectionFactory()); Stockholm 2010-09-14, WTFPL license

Contenu connexe

Tendances

Elasticsearch in 15 Minutes
Elasticsearch in 15 MinutesElasticsearch in 15 Minutes
Elasticsearch in 15 MinutesKarel Minarik
 
Elasticsearch (Rubyshift 2013)
Elasticsearch (Rubyshift 2013)Elasticsearch (Rubyshift 2013)
Elasticsearch (Rubyshift 2013)Karel Minarik
 
Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...
Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...
Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...Codemotion
 
Using MongoDB With Groovy
Using MongoDB With GroovyUsing MongoDB With Groovy
Using MongoDB With GroovyJames Williams
 
Connecting to a REST API in iOS
Connecting to a REST API in iOSConnecting to a REST API in iOS
Connecting to a REST API in iOSgillygize
 
Intermediate OOP in PHP
Intermediate OOP in PHPIntermediate OOP in PHP
Intermediate OOP in PHPDavid Stockton
 
Java Development with MongoDB (James Williams)
Java Development with MongoDB (James Williams)Java Development with MongoDB (James Williams)
Java Development with MongoDB (James Williams)MongoSF
 
Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3Peter Maas
 
Writing and using php streams and sockets
Writing and using php streams and socketsWriting and using php streams and sockets
Writing and using php streams and socketsElizabeth Smith
 
To Infinity & Beyond: Protocols & sequences in Node - Part 2
To Infinity & Beyond: Protocols & sequences in Node - Part 2To Infinity & Beyond: Protocols & sequences in Node - Part 2
To Infinity & Beyond: Protocols & sequences in Node - Part 2Bahul Neel Upadhyaya
 

Tendances (20)

Elasticsearch in 15 Minutes
Elasticsearch in 15 MinutesElasticsearch in 15 Minutes
Elasticsearch in 15 Minutes
 
Json the-x-in-ajax1588
Json the-x-in-ajax1588Json the-x-in-ajax1588
Json the-x-in-ajax1588
 
The emerging world of mongo db csp
The emerging world of mongo db   cspThe emerging world of mongo db   csp
The emerging world of mongo db csp
 
Elasticsearch (Rubyshift 2013)
Elasticsearch (Rubyshift 2013)Elasticsearch (Rubyshift 2013)
Elasticsearch (Rubyshift 2013)
 
Advanced JavaScript
Advanced JavaScriptAdvanced JavaScript
Advanced JavaScript
 
Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...
Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...
Making your elastic cluster perform - Jettro Coenradie - Codemotion Amsterdam...
 
J s-o-n-120219575328402-3
J s-o-n-120219575328402-3J s-o-n-120219575328402-3
J s-o-n-120219575328402-3
 
PHP Data Objects
PHP Data ObjectsPHP Data Objects
PHP Data Objects
 
Apache Thrift
Apache ThriftApache Thrift
Apache Thrift
 
Reversing JavaScript
Reversing JavaScriptReversing JavaScript
Reversing JavaScript
 
Cidán
CidánCidán
Cidán
 
Javascript2839
Javascript2839Javascript2839
Javascript2839
 
Using MongoDB With Groovy
Using MongoDB With GroovyUsing MongoDB With Groovy
Using MongoDB With Groovy
 
Connecting to a REST API in iOS
Connecting to a REST API in iOSConnecting to a REST API in iOS
Connecting to a REST API in iOS
 
Intermediate OOP in PHP
Intermediate OOP in PHPIntermediate OOP in PHP
Intermediate OOP in PHP
 
Java Development with MongoDB (James Williams)
Java Development with MongoDB (James Williams)Java Development with MongoDB (James Williams)
Java Development with MongoDB (James Williams)
 
Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3Domain Specific Languages In Scala Duse3
Domain Specific Languages In Scala Duse3
 
Python and MongoDB
Python and MongoDBPython and MongoDB
Python and MongoDB
 
Writing and using php streams and sockets
Writing and using php streams and socketsWriting and using php streams and sockets
Writing and using php streams and sockets
 
To Infinity & Beyond: Protocols & sequences in Node - Part 2
To Infinity & Beyond: Protocols & sequences in Node - Part 2To Infinity & Beyond: Protocols & sequences in Node - Part 2
To Infinity & Beyond: Protocols & sequences in Node - Part 2
 

En vedette

EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-
EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-
EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-Iten Mario Mendoza Camacho
 
Las comunidades de aprendizaje
Las comunidades de aprendizajeLas comunidades de aprendizaje
Las comunidades de aprendizajeEzequiel-Tarazona
 
Copernica - Cross Mail Presentatie
Copernica - Cross Mail PresentatieCopernica - Cross Mail Presentatie
Copernica - Cross Mail PresentatieCopernica BV
 
Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...
Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...
Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...María Dolores Sánchez-Fernández, PhD.
 
Oct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBase
Oct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBaseOct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBase
Oct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBaseYahoo Developer Network
 
Videreutdanning 160610
Videreutdanning 160610Videreutdanning 160610
Videreutdanning 160610hakva
 
Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)
Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)
Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)Esco Granada
 
“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...
“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...
“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...CIAT
 
Applus IAT BUMP
Applus IAT BUMPApplus IAT BUMP
Applus IAT BUMPwichyfly
 
Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...
Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...
Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...patrick werkt slimmer
 
Análisis de vibraciones de un tren de maquinaria
Análisis de vibraciones de un tren de maquinariaAnálisis de vibraciones de un tren de maquinaria
Análisis de vibraciones de un tren de maquinariaHipolito Condori
 
Presentacion Malaga CF Pedro Jimenez
Presentacion Malaga CF Pedro JimenezPresentacion Malaga CF Pedro Jimenez
Presentacion Malaga CF Pedro JimenezPedroJmnz
 
OpenStack at EBSCO
OpenStack at EBSCOOpenStack at EBSCO
OpenStack at EBSCOTesora
 
Historias y cuentos online
Historias y cuentos onlineHistorias y cuentos online
Historias y cuentos onlineJuan Quintana
 
El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...
El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...
El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...aljubarrota
 
Pizza Point Of Sale System - SpeedLine Overview
Pizza Point Of Sale System - SpeedLine OverviewPizza Point Of Sale System - SpeedLine Overview
Pizza Point Of Sale System - SpeedLine Overviewcarmensadie
 
Web Hooks and the Programmable World of Tomorrow
Web Hooks and the Programmable World of TomorrowWeb Hooks and the Programmable World of Tomorrow
Web Hooks and the Programmable World of TomorrowJeff Lindsay
 

En vedette (20)

EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-
EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-
EL MALPARIDO -NOVELA EN VERSIÓN DIGITAL GRATUITA-
 
Las comunidades de aprendizaje
Las comunidades de aprendizajeLas comunidades de aprendizaje
Las comunidades de aprendizaje
 
Copernica - Cross Mail Presentatie
Copernica - Cross Mail PresentatieCopernica - Cross Mail Presentatie
Copernica - Cross Mail Presentatie
 
XING for Universities
XING for UniversitiesXING for Universities
XING for Universities
 
Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...
Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...
Conferencia: Herramientas Estratégicas de Gestión: Responsabilidad Social Cor...
 
Oct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBase
Oct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBaseOct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBase
Oct 2012 HUG: Project Panthera: Better Analytics with SQL, MapReduce, and HBase
 
Videreutdanning 160610
Videreutdanning 160610Videreutdanning 160610
Videreutdanning 160610
 
Doug Hardenburgh Portfolio
Doug Hardenburgh PortfolioDoug Hardenburgh Portfolio
Doug Hardenburgh Portfolio
 
Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)
Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)
Presentación Proyecto Crónicas de Jóvenes Emprendedores (AJE Granada)
 
Lider
LiderLider
Lider
 
“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...
“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...
“Feria del Conocimiento América Latina y el Caribe: Casos destacados en agric...
 
Applus IAT BUMP
Applus IAT BUMPApplus IAT BUMP
Applus IAT BUMP
 
Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...
Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...
Tutorial / Manual / how-to-set-up: ’Remember the Milk’ as your task managemen...
 
Análisis de vibraciones de un tren de maquinaria
Análisis de vibraciones de un tren de maquinariaAnálisis de vibraciones de un tren de maquinaria
Análisis de vibraciones de un tren de maquinaria
 
Presentacion Malaga CF Pedro Jimenez
Presentacion Malaga CF Pedro JimenezPresentacion Malaga CF Pedro Jimenez
Presentacion Malaga CF Pedro Jimenez
 
OpenStack at EBSCO
OpenStack at EBSCOOpenStack at EBSCO
OpenStack at EBSCO
 
Historias y cuentos online
Historias y cuentos onlineHistorias y cuentos online
Historias y cuentos online
 
El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...
El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...
El tren de Arganda: trayecto ferroviario entre la estación del Niño Jesús y l...
 
Pizza Point Of Sale System - SpeedLine Overview
Pizza Point Of Sale System - SpeedLine OverviewPizza Point Of Sale System - SpeedLine Overview
Pizza Point Of Sale System - SpeedLine Overview
 
Web Hooks and the Programmable World of Tomorrow
Web Hooks and the Programmable World of TomorrowWeb Hooks and the Programmable World of Tomorrow
Web Hooks and the Programmable World of Tomorrow
 

Similaire à Introduction to terrastore

Architecture | Busy Java Developers Guide to NoSQL | Ted Neward
Architecture | Busy Java Developers Guide to NoSQL | Ted NewardArchitecture | Busy Java Developers Guide to NoSQL | Ted Neward
Architecture | Busy Java Developers Guide to NoSQL | Ted NewardJAX London
 
ElasticSearch for .NET Developers
ElasticSearch for .NET DevelopersElasticSearch for .NET Developers
ElasticSearch for .NET DevelopersBen van Mol
 
Xtend api and_dsl_design_patterns_eclipse_confrance2016
Xtend api and_dsl_design_patterns_eclipse_confrance2016Xtend api and_dsl_design_patterns_eclipse_confrance2016
Xtend api and_dsl_design_patterns_eclipse_confrance2016Max Bureck
 
Elastic search and Symfony3 - A practical approach
Elastic search and Symfony3 - A practical approachElastic search and Symfony3 - A practical approach
Elastic search and Symfony3 - A practical approachSymfonyMu
 
Fast SOA with Apache Synapse
Fast SOA with Apache SynapseFast SOA with Apache Synapse
Fast SOA with Apache SynapsePaul Fremantle
 
Javazone 2010-lift-framework-public
Javazone 2010-lift-framework-publicJavazone 2010-lift-framework-public
Javazone 2010-lift-framework-publicTimothy Perrett
 
Introduction to Thrift
Introduction to ThriftIntroduction to Thrift
Introduction to ThriftDvir Volk
 
Language processing patterns
Language processing patternsLanguage processing patterns
Language processing patternsRalf Laemmel
 
Hadoop and Cascading At AJUG July 2009
Hadoop and Cascading At AJUG July 2009Hadoop and Cascading At AJUG July 2009
Hadoop and Cascading At AJUG July 2009Christopher Curtin
 
XMLParser functionality demonstration...
XMLParser functionality demonstration...XMLParser functionality demonstration...
XMLParser functionality demonstration...bubnenkoff
 
Beyond javascript using the features of tomorrow
Beyond javascript   using the features of tomorrowBeyond javascript   using the features of tomorrow
Beyond javascript using the features of tomorrowAlexander Varwijk
 
Introduction to Spark with Scala
Introduction to Spark with ScalaIntroduction to Spark with Scala
Introduction to Spark with ScalaHimanshu Gupta
 
How Xslate Works
How Xslate WorksHow Xslate Works
How Xslate WorksGoro Fuji
 
Spark Summit East 2017: Apache spark and object stores
Spark Summit East 2017: Apache spark and object storesSpark Summit East 2017: Apache spark and object stores
Spark Summit East 2017: Apache spark and object storesSteve Loughran
 

Similaire à Introduction to terrastore (20)

Architecture | Busy Java Developers Guide to NoSQL | Ted Neward
Architecture | Busy Java Developers Guide to NoSQL | Ted NewardArchitecture | Busy Java Developers Guide to NoSQL | Ted Neward
Architecture | Busy Java Developers Guide to NoSQL | Ted Neward
 
Processing XML with Java
Processing XML with JavaProcessing XML with Java
Processing XML with Java
 
ElasticSearch for .NET Developers
ElasticSearch for .NET DevelopersElasticSearch for .NET Developers
ElasticSearch for .NET Developers
 
Xtend api and_dsl_design_patterns_eclipse_confrance2016
Xtend api and_dsl_design_patterns_eclipse_confrance2016Xtend api and_dsl_design_patterns_eclipse_confrance2016
Xtend api and_dsl_design_patterns_eclipse_confrance2016
 
Elastic search and Symfony3 - A practical approach
Elastic search and Symfony3 - A practical approachElastic search and Symfony3 - A practical approach
Elastic search and Symfony3 - A practical approach
 
Fast SOA with Apache Synapse
Fast SOA with Apache SynapseFast SOA with Apache Synapse
Fast SOA with Apache Synapse
 
Javazone 2010-lift-framework-public
Javazone 2010-lift-framework-publicJavazone 2010-lift-framework-public
Javazone 2010-lift-framework-public
 
Introduction to Thrift
Introduction to ThriftIntroduction to Thrift
Introduction to Thrift
 
Language processing patterns
Language processing patternsLanguage processing patterns
Language processing patterns
 
Handling Markup Overlaps Using OWL
Handling Markup Overlaps Using OWLHandling Markup Overlaps Using OWL
Handling Markup Overlaps Using OWL
 
Hadoop and Cascading At AJUG July 2009
Hadoop and Cascading At AJUG July 2009Hadoop and Cascading At AJUG July 2009
Hadoop and Cascading At AJUG July 2009
 
XMLParser functionality demonstration...
XMLParser functionality demonstration...XMLParser functionality demonstration...
XMLParser functionality demonstration...
 
Json
JsonJson
Json
 
Ontopia Code Camp
Ontopia Code CampOntopia Code Camp
Ontopia Code Camp
 
Beyond javascript using the features of tomorrow
Beyond javascript   using the features of tomorrowBeyond javascript   using the features of tomorrow
Beyond javascript using the features of tomorrow
 
Dart on server - Meetup 18/05/2017
Dart on server - Meetup 18/05/2017Dart on server - Meetup 18/05/2017
Dart on server - Meetup 18/05/2017
 
Introduction to Spark with Scala
Introduction to Spark with ScalaIntroduction to Spark with Scala
Introduction to Spark with Scala
 
How Xslate Works
How Xslate WorksHow Xslate Works
How Xslate Works
 
Spark Summit East 2017: Apache spark and object stores
Spark Summit East 2017: Apache spark and object storesSpark Summit East 2017: Apache spark and object stores
Spark Summit East 2017: Apache spark and object stores
 
Tales@tdc
Tales@tdcTales@tdc
Tales@tdc
 

Dernier

VoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBXVoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBXTarek Kalaji
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1DianaGray10
 
20230202 - Introduction to tis-py
20230202 - Introduction to tis-py20230202 - Introduction to tis-py
20230202 - Introduction to tis-pyJamie (Taka) Wang
 
Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™Adtran
 
Building AI-Driven Apps Using Semantic Kernel.pptx
Building AI-Driven Apps Using Semantic Kernel.pptxBuilding AI-Driven Apps Using Semantic Kernel.pptx
Building AI-Driven Apps Using Semantic Kernel.pptxUdaiappa Ramachandran
 
COMPUTER 10 Lesson 8 - Building a Website
COMPUTER 10 Lesson 8 - Building a WebsiteCOMPUTER 10 Lesson 8 - Building a Website
COMPUTER 10 Lesson 8 - Building a Websitedgelyza
 
Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.YounusS2
 
Computer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsComputer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsSeth Reyes
 
Cybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptxCybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptxGDSC PJATK
 
Designing A Time bound resource download URL
Designing A Time bound resource download URLDesigning A Time bound resource download URL
Designing A Time bound resource download URLRuncy Oommen
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024SkyPlanner
 
NIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 WorkshopNIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 WorkshopBachir Benyammi
 
OpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureOpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureEric D. Schabell
 
Bird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystemBird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystemAsko Soukka
 
Linked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesLinked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesDavid Newbury
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaborationbruanjhuli
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdfPedro Manuel
 
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...DianaGray10
 
AI You Can Trust - Ensuring Success with Data Integrity Webinar
AI You Can Trust - Ensuring Success with Data Integrity WebinarAI You Can Trust - Ensuring Success with Data Integrity Webinar
AI You Can Trust - Ensuring Success with Data Integrity WebinarPrecisely
 

Dernier (20)

VoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBXVoIP Service and Marketing using Odoo and Asterisk PBX
VoIP Service and Marketing using Odoo and Asterisk PBX
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1
 
20230202 - Introduction to tis-py
20230202 - Introduction to tis-py20230202 - Introduction to tis-py
20230202 - Introduction to tis-py
 
Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™Meet the new FSP 3000 M-Flex800™
Meet the new FSP 3000 M-Flex800™
 
Building AI-Driven Apps Using Semantic Kernel.pptx
Building AI-Driven Apps Using Semantic Kernel.pptxBuilding AI-Driven Apps Using Semantic Kernel.pptx
Building AI-Driven Apps Using Semantic Kernel.pptx
 
COMPUTER 10 Lesson 8 - Building a Website
COMPUTER 10 Lesson 8 - Building a WebsiteCOMPUTER 10 Lesson 8 - Building a Website
COMPUTER 10 Lesson 8 - Building a Website
 
Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.
 
Computer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsComputer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and Hazards
 
Cybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptxCybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptx
 
Designing A Time bound resource download URL
Designing A Time bound resource download URLDesigning A Time bound resource download URL
Designing A Time bound resource download URL
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024
 
NIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 WorkshopNIST Cybersecurity Framework (CSF) 2.0 Workshop
NIST Cybersecurity Framework (CSF) 2.0 Workshop
 
OpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability AdventureOpenShift Commons Paris - Choose Your Own Observability Adventure
OpenShift Commons Paris - Choose Your Own Observability Adventure
 
Bird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystemBird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystem
 
Linked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesLinked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond Ontologies
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdf
 
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
Connector Corner: Extending LLM automation use cases with UiPath GenAI connec...
 
20230104 - machine vision
20230104 - machine vision20230104 - machine vision
20230104 - machine vision
 
AI You Can Trust - Ensuring Success with Data Integrity Webinar
AI You Can Trust - Ensuring Success with Data Integrity WebinarAI You Can Trust - Ensuring Success with Data Integrity Webinar
AI You Can Trust - Ensuring Success with Data Integrity Webinar
 

Introduction to terrastore

  • 1. Introduction to Terrastore Sven Johansson Mejsla @svjson Mats Henricson Crisp @matshenricson
  • 2. NoSQL - A loosely defined movement - A complement to relational databases - Usually schema-less - Typically not concerned with transactions, locks or data integrity... - ...but more so with performance and scalability
  • 3.
  • 7. Terrastore - Open source project founded in Sept-Oct 2009 - Written entirely in Java - Based on Terracotta - Offers per-document consistency - Distributed - Elastic - Scalable at the computational level - Extensible
  • 8. A Terrastore document { 'name' : 'Sven Johansson', 'age' : '29', 'titles' : [ 'Developer', 'Consultant', 'Destroyer of worlds', ], 'currentlyReading : { title: 'The book of Dave' author: 'Will Self' } 'favouriteBooks' : [{ title: 'The naked and the dead', author: 'Norman Mailer' }, { title: 'On the road', author: 'Jack Kerouac' }] }
  • 9. public class Person { private String name; private int age; private String[] titles; private Book currentlyReading; private List<Book> favouriteBooks; ... } ...and a corresponding Java Object
  • 10. Deployment architecture Single cluster - 1 Master - n Servers ( n hot standbys)
  • 11. Deployment architecture Multi-cluster (Ensemble) - Cluster of n Masters - n Servers each
  • 12. CRUD with Terrastore Mats Henricson Crisp AB Stockholm 2010-09-14, WTFPL license
  • 13. Example public class Customer { private String name; private Address address; private List<PhoneNumber> phoneNumbers = new LinkedList<PhoneNumber>(); // ... } public class Address { private String street; // ... } public class PhoneNumber { private String number; private String type; // … } } Stockholm 2010-09-14, WTFPL license
  • 14. Annotations? Base classes? Nope. The POJO:s are plain vanilla vanilla POJO:s Stockholm 2010-09-14, WTFPL license
  • 15.
  • 16. One bucket for item data
  • 17. One bucket for orders Stockholm 2010-09-14, WTFPL license
  • 18. First we need a terrastore client That localhost URL points to a terrastore server . If that server goes down, then your client is toast. Next version of the API have implemented fallbacks. Enough! I want an example, now! TerrastoreClient client = new TerrastoreClient(&quot;http://localhost:8080&quot;, new HTTPConnectionFactory()); Stockholm 2010-09-14, WTFPL license
  • 19. Customer lindex = new Customer(&quot;Lindex&quot;); Address dg = new Address(&quot;Drottninggatan 77&quot;); PhoneNumber work = new PhoneNumber(&quot;1234567&quot;, &quot;work&quot;); PhoneNumber home = new PhoneNumber(&quot;2345678&quot;, &quot;home&quot;); // Set relationships lindex.setAddress(dg); lindex.addPhoneNumber(work); lindex.addPhoneNumber(home); Now lets create the POJO:s Stockholm 2010-09-14, WTFPL license
  • 20. BucketOperation customers = client.bucket(&quot;customers&quot;); // Create: customers.key(&quot;lindex&quot;).put(lindex); // Read: Customer l = customers.key(&quot;lindex&quot;).get(Customer.class); // Important: l != lindex // Delete: customers.key(&quot;lindex&quot;).remove(); Create, Read and Delete You can update a document with another put() Stockholm 2010-09-14, WTFPL license
  • 21.
  • 22. Get for non-existing keys will throw KeyNotFoundException
  • 23. You can import and export whole buckets to file for backup
  • 24. You can get all documents in a bucket
  • 25. You can get n documents in a bucket
  • 26. You can get all documents within a key range
  • 27. You can read old documents into objects of updated classes No, there is a lot more cool stuff! Stockholm 2010-09-14, WTFPL license
  • 28. Search example with ranges Map<String, Customer> customers = customersBucket.range(&quot;lexical-asc&quot;) .from(&quot;brothers&quot;).to(&quot;lindex&quot;) .limit(10).get(Customer.class); Stockholm 2010-09-14, WTFPL license
  • 29. String xpath = &quot;jxpath:/address/street[.='Drottninggatan 77']&quot;; Map<String, Customer> dgCustomers = customersBucket.predicate(xpath).get(Customer.class); assertTrue(dgCustomers.containsValue(lindex)); XPath! Internally using JXPath. Stockholm 2010-09-14, WTFPL license