SlideShare a Scribd company logo
Designing API for
Databases:
‪ Which one should you pick ?
GraphQL
@clunven | #voxxed_lu | @voxxed_lu
Casino 2000, Luxembourg
@clunven | @voxxed_lu | #voxxed_lu
About me
Cedrick Lunven
Developer Advocate
Creator Contributor
© DataStax, All Rights Reserved.Confidential © DataStax, All Rights Reserved.
Agenda 2
3
4 DECISION TREE
DEMONSTRATION AND CODE REVIEW
API DESIGN METHODOLOGY
1 APACHE CASSANDRA™ OVERVIEW
APACHE CASSANDRA™
Quick Overview
@clunven | @voxxed_lu | #voxxed_lu
This is a DISTRIBUTED Database
Node
• Up to 1TB
• 3000 Tx/s/core
@clunven | @voxxed_lu | #voxxed_lu
…which scale linearly
@clunven | @voxxed_lu | #voxxed_lu
Data is distributed
0
13
25
38
50
63
75
88 59 (data)
RF=2
59 (data)
RF=3
replicated
@clunven | @voxxed_lu | #voxxed_lu
Cassandra is « AP »
Consistency
Partition
Tolerance
Availability
@clunven | @voxxed_lu | #voxxed_lu
Tuneable Consistency
RF=3
Client CL=ONECL=QUORUMCL=ALL
@clunven | @voxxed_lu | #voxxed_lu
…anywhere
Cluster
Datacenter (Ring)
@clunven | @voxxed_lu | #voxxed_lu
Sweet spots
1. High Throughput (because we can keep up)
2. High Volume (because we scale linearly and still OLTP)
3. High Availability (replication, masterless)
4. Data distribution (read/write around the globe)
@clunven | @voxxed_lu | #voxxed_lu
• Le KEYSPACE est comme un schéma
dans Oracle, une isolation des
données
12
Projet_X Keyspace
Une table contient une CLEF
PRIMAIRE contenant 2 parties : La
partition key et le reste (clustering
columns). Chaque valeur de
partition key est hashée sous la
forme d’un token.
Plusieurs lignes avec la même
partition key constitue une
partition.
Data Modelling
@clunven | @voxxed_lu | #voxxed_lu
• Syntaxe proche du SQL pour
les bases relationnelles
• Création des objets avec le
DDL :
• CREATE, INSERT, UPDATE,
DELETE, GRANT, REVOKE,
SELECT, WHERE
13
Exemple
CREATE TABLE market_prices (
symbol TEXT,
date TIMESTAMP,
price DECIMAL,
side INT,
PRIMARY KEY (symbol, date)
) WITH CLUSTERING ORDER BY(date DESC);
Cassandra Query Language
LIST, SET, MAP, UDT
API DESIGN METHODOLOGY
From zero to hero
@clunven | @voxxed_lu | #voxxed_lu
Reference Application
http://killrvideo.github.io
@clunven | @voxxed_lu | #voxxed_lu
Api Design Methodology
1
killrvideo-dse
Drivers
DAO3
killrvideo-api-rest killrvideo-api-grpc killrvideo-api-graphql
2
@clunven | @voxxed_lu | #voxxed_lu
Designing Data Model
Entities & Relationships
Queries
@clunven | @voxxed_lu | #voxxed_lu
Conceptual Data Model
@clunven | @voxxed_lu | #voxxed_lu
Application Workflow
R1: Find comments related to target video using its identifier
• Get most recent first
• Implement Paging
R2: Find comments related to target user using its identifier
• Get most recent first
• Implement Paging
R3: Implement CRUD operations
@clunven | @voxxed_lu | #voxxed_lu
Mapping
Q2: Find comments posted for a user with a
known id (show most recent first)
comments_by_video
comments_by_user
Q1: Find comments for a video with a
known id (show most recent first)
Q3: CRUD Operations
@clunven | @voxxed_lu | #voxxed_lu
Logical Data Model
userid
creationdate
commentid
videoid
comment
comments_by_user
K
C
↑
videoid
creationdate
commentid
userid
comment
comments_by_video
C
↑
K
C
↑
↑C
@clunven | @voxxed_lu | #voxxed_lu
Physical Data Model
userid
commentid
videoid
comment
comments_by_user
TIMEUUID
K
TEXT
C
UUID
UUID
↑
videoid
commentid
userid
comment
comments_by_video
TIMEUUID
K
TEXT
C
UUID
UUID
↑
@clunven | @voxxed_lu | #voxxed_lu
Schema DDL
CREATE TABLE IF NOT EXISTS comments_by_user (
userid uuid,
commentid timeuuid,
videoid uuid,
comment text,
PRIMARY KEY ((userid), commentid)
) WITH CLUSTERING ORDER BY (commentid DESC);
CREATE TABLE IF NOT EXISTS comments_by_video (
videoid uuid,
commentid timeuuid,
userid uuid,
comment text,
PRIMARY KEY ((videoid), commentid)
) WITH CLUSTERING ORDER BY (commentid DESC);
@clunven | @voxxed_lu | #voxxed_lu
How?
Conceptual Data
Model
(Entities, Relations)
Application Workflow
(Queries)
Database Family
(Technos +Table)
@clunven | @voxxed_lu | #voxxed_lu
@clunven | @voxxed_lu | #voxxed_lu
DECISION TREE
Because we are serious
@clunven | @voxxed_lu | #voxxed_lu
Analysis Criteria
📋 Conceptual
Data Model
Application
Workflow
(Queries)
Database Family
(Technos
+Table)
Caching
Syncvs AsyncReactive
SLA (Volume)
Data Integrity
Filters
Paging
Sort
Latencies Throughput
Versionning
Confidentiality
Atomicity
Cardinality
Developers
👤 Users/Consumers
Language
CodeFirst/
Vs SchemaFirst
Documentation
Test
Build
Packaging
Api Catalog
Internalvs
Public Techno
Profile
XP
@clunven | @voxxed_lu | #voxxed_lu
Analysis Matrix
@clunven | @voxxed_lu | #voxxed_lu
Decision Tree
@clunven | @voxxed_lu | #voxxed_lu
 Decoupling Client / Server (Schema on read)
 Flexibility: Sync, Async, Reactive + Multi payload
 Api Lifecycle (Versioning)
 Tooling (API Management, Serverless)
 Verbose payloads (json, xml)
 No discoverability
 Not best fit for command-like (functions) API (RPC)
 CRUD superstar
 Relevant for OLTP mutations and statuses
 Public and web APIs
@clunven | @voxxed_lu | #voxxed_lu
 High Performances (http/2 – binary serialisation)
 Multiple stubs : Sync, Async, Streaming
 Multi languages (Interoperability)
 Strongly coupled (schema with proto files)
 No discoverability
 Protobuf serialization format
 Distributed network of services (no waits)
 High throughput & streaming use cases
 Command-like, RPC
@clunven | @voxxed_lu | #voxxed_lu
 Discoverability, documentation
 Custom payloads
 Match standards (Json | Http)
 Single endpoint (versioning, monitoring, security)
 Complex implementation (tooling, still young)
 Nice for customers nasty for DB (N+1 select)
 BFF : Backend for frontend
 Service aggregation | composition (joins)
 When bandwidth matters (mobile phones)
GraphQL
RESOURCES
Because COPY/PASTE is the most important skill for developers
@clunven | @voxxed_lu | #voxxed_lu
References
https://github.com/clun/api_Rest_Grpc_GraphQL
THANK YOU

More Related Content

What's hot

Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks
Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks
Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks
DataWorks Summit/Hadoop Summit
 
Big Data-Driven Applications with Cassandra and Spark
Big Data-Driven Applications  with Cassandra and SparkBig Data-Driven Applications  with Cassandra and Spark
Big Data-Driven Applications with Cassandra and SparkArtem Chebotko
 
Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...
Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...
Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...
Cedric CARBONE
 
What's new in pandas and the SciPy stack for financial users
What's new in pandas and the SciPy stack for financial usersWhat's new in pandas and the SciPy stack for financial users
What's new in pandas and the SciPy stack for financial usersWes McKinney
 
Realtime Data Analysis Patterns
Realtime Data Analysis PatternsRealtime Data Analysis Patterns
Realtime Data Analysis Patterns
Mikio L. Braun
 
Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...
Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...
Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...
Brian O'Neill
 
Introducing Kafka Connect and Implementing Custom Connectors
Introducing Kafka Connect and Implementing Custom ConnectorsIntroducing Kafka Connect and Implementing Custom Connectors
Introducing Kafka Connect and Implementing Custom Connectors
Itai Yaffe
 
FlinkML: Large Scale Machine Learning with Apache Flink
FlinkML: Large Scale Machine Learning with Apache FlinkFlinkML: Large Scale Machine Learning with Apache Flink
FlinkML: Large Scale Machine Learning with Apache Flink
Theodoros Vasiloudis
 
Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...
Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...
Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...
MLconf
 
Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...
Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...
Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...
guest5b1607
 
Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...
Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...
Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...
Jen Aman
 
New Analytics Toolbox DevNexus 2015
New Analytics Toolbox DevNexus 2015New Analytics Toolbox DevNexus 2015
New Analytics Toolbox DevNexus 2015
Robbie Strickland
 
Always On: Building Highly Available Applications on Cassandra
Always On: Building Highly Available Applications on CassandraAlways On: Building Highly Available Applications on Cassandra
Always On: Building Highly Available Applications on Cassandra
Robbie Strickland
 
Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16
Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16
Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16
MLconf
 
GluonNLP MXNet Meetup-Aug
GluonNLP MXNet Meetup-AugGluonNLP MXNet Meetup-Aug
GluonNLP MXNet Meetup-Aug
Chenguang Wang
 
Graph x pregel
Graph x pregelGraph x pregel
Graph x pregel
Sigmoid
 
Spec: a lisp-flavoured type system
Spec: a lisp-flavoured type systemSpec: a lisp-flavoured type system
Spec: a lisp-flavoured type system
Simon Belak
 
Graph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4jGraph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4j
Neo4j
 
Seattle Scalability Mahout
Seattle Scalability MahoutSeattle Scalability Mahout
Seattle Scalability Mahout
Jake Mannix
 
Graphity - Generic Linked Data Platform
Graphity - Generic Linked Data PlatformGraphity - Generic Linked Data Platform
Graphity - Generic Linked Data Platform
Julius Šėporaitis
 

What's hot (20)

Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks
Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks
Exploring Titan and Spark GraphX for Analyzing Time-Varying Electrical Networks
 
Big Data-Driven Applications with Cassandra and Spark
Big Data-Driven Applications  with Cassandra and SparkBig Data-Driven Applications  with Cassandra and Spark
Big Data-Driven Applications with Cassandra and Spark
 
Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...
Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...
Paris Spark Meetup (Feb2015) ccarbone : SPARK Streaming vs Storm / MLLib / Ne...
 
What's new in pandas and the SciPy stack for financial users
What's new in pandas and the SciPy stack for financial usersWhat's new in pandas and the SciPy stack for financial users
What's new in pandas and the SciPy stack for financial users
 
Realtime Data Analysis Patterns
Realtime Data Analysis PatternsRealtime Data Analysis Patterns
Realtime Data Analysis Patterns
 
Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...
Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...
Data Pipelines & Integrating Real-time Web Services w/ Storm : Improving on t...
 
Introducing Kafka Connect and Implementing Custom Connectors
Introducing Kafka Connect and Implementing Custom ConnectorsIntroducing Kafka Connect and Implementing Custom Connectors
Introducing Kafka Connect and Implementing Custom Connectors
 
FlinkML: Large Scale Machine Learning with Apache Flink
FlinkML: Large Scale Machine Learning with Apache FlinkFlinkML: Large Scale Machine Learning with Apache Flink
FlinkML: Large Scale Machine Learning with Apache Flink
 
Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...
Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...
Mathias Brandewinder, Software Engineer & Data Scientist, Clear Lines Consult...
 
Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...
Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...
Text Analytics Summit 2009 - Roddy Lindsay - "Social Media, Happiness, Petaby...
 
Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...
Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...
Massive Simulations In Spark: Distributed Monte Carlo For Global Health Forec...
 
New Analytics Toolbox DevNexus 2015
New Analytics Toolbox DevNexus 2015New Analytics Toolbox DevNexus 2015
New Analytics Toolbox DevNexus 2015
 
Always On: Building Highly Available Applications on Cassandra
Always On: Building Highly Available Applications on CassandraAlways On: Building Highly Available Applications on Cassandra
Always On: Building Highly Available Applications on Cassandra
 
Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16
Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16
Jake Mannix, Lead Data Engineer, Lucidworks at MLconf SEA - 5/20/16
 
GluonNLP MXNet Meetup-Aug
GluonNLP MXNet Meetup-AugGluonNLP MXNet Meetup-Aug
GluonNLP MXNet Meetup-Aug
 
Graph x pregel
Graph x pregelGraph x pregel
Graph x pregel
 
Spec: a lisp-flavoured type system
Spec: a lisp-flavoured type systemSpec: a lisp-flavoured type system
Spec: a lisp-flavoured type system
 
Graph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4jGraph Analytics: Graph Algorithms Inside Neo4j
Graph Analytics: Graph Algorithms Inside Neo4j
 
Seattle Scalability Mahout
Seattle Scalability MahoutSeattle Scalability Mahout
Seattle Scalability Mahout
 
Graphity - Generic Linked Data Platform
Graphity - Generic Linked Data PlatformGraphity - Generic Linked Data Platform
Graphity - Generic Linked Data Platform
 

Similar to VoxxedDays Luxembourg 2019

Azure Cosmos DB - Technical Deep Dive
Azure Cosmos DB - Technical Deep DiveAzure Cosmos DB - Technical Deep Dive
Azure Cosmos DB - Technical Deep Dive
Andre Essing
 
Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習
Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習 Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習
Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習
Herman Wu
 
Stargate, the gateway for some multi-models data API
Stargate, the gateway for some multi-models data APIStargate, the gateway for some multi-models data API
Stargate, the gateway for some multi-models data API
Data Con LA
 
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and SparkVital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital.AI
 
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI ProjectsDiscovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Wee Hyong Tok
 
Declarative benchmarking of cassandra and it's data models
Declarative benchmarking of cassandra and it's data modelsDeclarative benchmarking of cassandra and it's data models
Declarative benchmarking of cassandra and it's data models
Monal Daxini
 
Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...
Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...
Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...
Andre Essing
 
6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...
6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...
6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...
Jürgen Ambrosi
 
From Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's Data
From Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's DataFrom Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's Data
From Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's Data
Databricks
 
NextGenML
NextGenML NextGenML
Dev Ops Training
Dev Ops TrainingDev Ops Training
Dev Ops Training
Spark Summit
 
Shift Dev Conf API
Shift Dev Conf APIShift Dev Conf API
Shift Dev Conf API
Cédrick Lunven
 
AnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsight
AnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsightAnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsight
AnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsight
Łukasz Grala
 
Streaming, Analytics and Reactive Applications with Apache Cassandra
Streaming, Analytics and Reactive Applications with Apache CassandraStreaming, Analytics and Reactive Applications with Apache Cassandra
Streaming, Analytics and Reactive Applications with Apache Cassandra
Cédrick Lunven
 
20160317 - PAZUR - PowerBI & R
20160317  - PAZUR - PowerBI & R20160317  - PAZUR - PowerBI & R
20160317 - PAZUR - PowerBI & R
Łukasz Grala
 
Hopsworks - Self-Service Spark/Flink/Kafka/Hadoop
Hopsworks - Self-Service Spark/Flink/Kafka/HadoopHopsworks - Self-Service Spark/Flink/Kafka/Hadoop
Hopsworks - Self-Service Spark/Flink/Kafka/Hadoop
Jim Dowling
 
Autonomous analytics on streaming data
Autonomous analytics on streaming dataAutonomous analytics on streaming data
Autonomous analytics on streaming data
Claudiu Barbura
 
LarKC Tutorial at ISWC 2009 - Introduction
LarKC Tutorial at ISWC 2009 - IntroductionLarKC Tutorial at ISWC 2009 - Introduction
LarKC Tutorial at ISWC 2009 - Introduction
LarKC
 
Natural Language Processing with CNTK and Apache Spark with Ali Zaidi
Natural Language Processing with CNTK and Apache Spark with Ali ZaidiNatural Language Processing with CNTK and Apache Spark with Ali Zaidi
Natural Language Processing with CNTK and Apache Spark with Ali Zaidi
Databricks
 
Source-to-source transformations: Supporting tools and infrastructure
Source-to-source transformations: Supporting tools and infrastructureSource-to-source transformations: Supporting tools and infrastructure
Source-to-source transformations: Supporting tools and infrastructure
kaveirious
 

Similar to VoxxedDays Luxembourg 2019 (20)

Azure Cosmos DB - Technical Deep Dive
Azure Cosmos DB - Technical Deep DiveAzure Cosmos DB - Technical Deep Dive
Azure Cosmos DB - Technical Deep Dive
 
Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習
Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習 Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習
Azure 機器學習 - 使用Python, R, Spark, CNTK 深度學習
 
Stargate, the gateway for some multi-models data API
Stargate, the gateway for some multi-models data APIStargate, the gateway for some multi-models data API
Stargate, the gateway for some multi-models data API
 
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and SparkVital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
Vital AI MetaQL: Queries Across NoSQL, SQL, Sparql, and Spark
 
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI ProjectsDiscovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
Discovering Your AI Super Powers - Tips and Tricks to Jumpstart your AI Projects
 
Declarative benchmarking of cassandra and it's data models
Declarative benchmarking of cassandra and it's data modelsDeclarative benchmarking of cassandra and it's data models
Declarative benchmarking of cassandra and it's data models
 
Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...
Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...
Azure Cosmos DB - NoSQL Strikes Back (An introduction to the dark side of you...
 
6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...
6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...
6° Sessione - Ambiti applicativi nella ricerca di tecnologie statistiche avan...
 
From Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's Data
From Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's DataFrom Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's Data
From Pandas to Koalas: Reducing Time-To-Insight for Virgin Hyperloop's Data
 
NextGenML
NextGenML NextGenML
NextGenML
 
Dev Ops Training
Dev Ops TrainingDev Ops Training
Dev Ops Training
 
Shift Dev Conf API
Shift Dev Conf APIShift Dev Conf API
Shift Dev Conf API
 
AnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsight
AnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsightAnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsight
AnalyticsConf2016 - Zaawansowana analityka na platformie Azure HDInsight
 
Streaming, Analytics and Reactive Applications with Apache Cassandra
Streaming, Analytics and Reactive Applications with Apache CassandraStreaming, Analytics and Reactive Applications with Apache Cassandra
Streaming, Analytics and Reactive Applications with Apache Cassandra
 
20160317 - PAZUR - PowerBI & R
20160317  - PAZUR - PowerBI & R20160317  - PAZUR - PowerBI & R
20160317 - PAZUR - PowerBI & R
 
Hopsworks - Self-Service Spark/Flink/Kafka/Hadoop
Hopsworks - Self-Service Spark/Flink/Kafka/HadoopHopsworks - Self-Service Spark/Flink/Kafka/Hadoop
Hopsworks - Self-Service Spark/Flink/Kafka/Hadoop
 
Autonomous analytics on streaming data
Autonomous analytics on streaming dataAutonomous analytics on streaming data
Autonomous analytics on streaming data
 
LarKC Tutorial at ISWC 2009 - Introduction
LarKC Tutorial at ISWC 2009 - IntroductionLarKC Tutorial at ISWC 2009 - Introduction
LarKC Tutorial at ISWC 2009 - Introduction
 
Natural Language Processing with CNTK and Apache Spark with Ali Zaidi
Natural Language Processing with CNTK and Apache Spark with Ali ZaidiNatural Language Processing with CNTK and Apache Spark with Ali Zaidi
Natural Language Processing with CNTK and Apache Spark with Ali Zaidi
 
Source-to-source transformations: Supporting tools and infrastructure
Source-to-source transformations: Supporting tools and infrastructureSource-to-source transformations: Supporting tools and infrastructure
Source-to-source transformations: Supporting tools and infrastructure
 

More from Cédrick Lunven

Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)
Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)
Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)
Cédrick Lunven
 
BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...
BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...
BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...
Cédrick Lunven
 
Avoiding Pitfalls for Cassandra.pdf
Avoiding Pitfalls for Cassandra.pdfAvoiding Pitfalls for Cassandra.pdf
Avoiding Pitfalls for Cassandra.pdf
Cédrick Lunven
 
Unlock cassandra data for application developers using graphQL
Unlock cassandra data for application developers using graphQLUnlock cassandra data for application developers using graphQL
Unlock cassandra data for application developers using graphQL
Cédrick Lunven
 
An oss api layer for your cassandra
An oss api layer for your cassandraAn oss api layer for your cassandra
An oss api layer for your cassandra
Cédrick Lunven
 
CN Asturias - Stateful application for kubernetes
CN Asturias -  Stateful application for kubernetes CN Asturias -  Stateful application for kubernetes
CN Asturias - Stateful application for kubernetes
Cédrick Lunven
 
Xebicon2019 m icroservices
Xebicon2019   m icroservicesXebicon2019   m icroservices
Xebicon2019 m icroservices
Cédrick Lunven
 
DevFestBdm2019
DevFestBdm2019DevFestBdm2019
DevFestBdm2019
Cédrick Lunven
 
Reactive Programming with Cassandra
Reactive Programming with CassandraReactive Programming with Cassandra
Reactive Programming with Cassandra
Cédrick Lunven
 
VoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4JVoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4J
Cédrick Lunven
 
Design API - SnowCampIO
Design API - SnowCampIODesign API - SnowCampIO
Design API - SnowCampIO
Cédrick Lunven
 
Create API for your Databases
Create API for your DatabasesCreate API for your Databases
Create API for your Databases
Cédrick Lunven
 
Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...
Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...
Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...
Cédrick Lunven
 
Riviera jug apicassandra
Riviera jug apicassandraRiviera jug apicassandra
Riviera jug apicassandra
Cédrick Lunven
 
Riviera JUG ff4j
Riviera JUG ff4jRiviera JUG ff4j
Riviera JUG ff4j
Cédrick Lunven
 
Paris Meetup Jhispter #9 - Generator FF4j for Jhipster
Paris Meetup Jhispter #9 - Generator FF4j for JhipsterParis Meetup Jhispter #9 - Generator FF4j for Jhipster
Paris Meetup Jhispter #9 - Generator FF4j for Jhipster
Cédrick Lunven
 
Introduction to Feature Toggle and FF4J
Introduction to Feature Toggle and FF4JIntroduction to Feature Toggle and FF4J
Introduction to Feature Toggle and FF4J
Cédrick Lunven
 

More from Cédrick Lunven (17)

Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)
Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)
Top 10 present and future innovations in the NoSQL Cassandra ecosystem (2022)
 
BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...
BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...
BigData Paris 2022 - Innovations récentes et futures autour du NoSQL Apache ...
 
Avoiding Pitfalls for Cassandra.pdf
Avoiding Pitfalls for Cassandra.pdfAvoiding Pitfalls for Cassandra.pdf
Avoiding Pitfalls for Cassandra.pdf
 
Unlock cassandra data for application developers using graphQL
Unlock cassandra data for application developers using graphQLUnlock cassandra data for application developers using graphQL
Unlock cassandra data for application developers using graphQL
 
An oss api layer for your cassandra
An oss api layer for your cassandraAn oss api layer for your cassandra
An oss api layer for your cassandra
 
CN Asturias - Stateful application for kubernetes
CN Asturias -  Stateful application for kubernetes CN Asturias -  Stateful application for kubernetes
CN Asturias - Stateful application for kubernetes
 
Xebicon2019 m icroservices
Xebicon2019   m icroservicesXebicon2019   m icroservices
Xebicon2019 m icroservices
 
DevFestBdm2019
DevFestBdm2019DevFestBdm2019
DevFestBdm2019
 
Reactive Programming with Cassandra
Reactive Programming with CassandraReactive Programming with Cassandra
Reactive Programming with Cassandra
 
VoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4JVoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4J
 
Design API - SnowCampIO
Design API - SnowCampIODesign API - SnowCampIO
Design API - SnowCampIO
 
Create API for your Databases
Create API for your DatabasesCreate API for your Databases
Create API for your Databases
 
Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...
Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...
Leveraging Feature Toggles for your Microservices (VoxxeddaysMicroservices Pa...
 
Riviera jug apicassandra
Riviera jug apicassandraRiviera jug apicassandra
Riviera jug apicassandra
 
Riviera JUG ff4j
Riviera JUG ff4jRiviera JUG ff4j
Riviera JUG ff4j
 
Paris Meetup Jhispter #9 - Generator FF4j for Jhipster
Paris Meetup Jhispter #9 - Generator FF4j for JhipsterParis Meetup Jhispter #9 - Generator FF4j for Jhipster
Paris Meetup Jhispter #9 - Generator FF4j for Jhipster
 
Introduction to Feature Toggle and FF4J
Introduction to Feature Toggle and FF4JIntroduction to Feature Toggle and FF4J
Introduction to Feature Toggle and FF4J
 

Recently uploaded

Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
91mobiles
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
Video Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the FutureVideo Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the Future
Alpen-Adria-Universität
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
nkrafacyberclub
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Aggregage
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
sonjaschweigert1
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
RinaMondal9
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
Peter Spielvogel
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
ThomasParaiso2
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
DianaGray10
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
Matthew Sinclair
 

Recently uploaded (20)

Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
Video Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the FutureVideo Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the Future
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptxSecstrike : Reverse Engineering & Pwnable tools for CTF.pptx
Secstrike : Reverse Engineering & Pwnable tools for CTF.pptx
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
 

VoxxedDays Luxembourg 2019

  • 1. Designing API for Databases: ‪ Which one should you pick ? GraphQL @clunven | #voxxed_lu | @voxxed_lu Casino 2000, Luxembourg
  • 2. @clunven | @voxxed_lu | #voxxed_lu About me Cedrick Lunven Developer Advocate Creator Contributor
  • 3. © DataStax, All Rights Reserved.Confidential © DataStax, All Rights Reserved. Agenda 2 3 4 DECISION TREE DEMONSTRATION AND CODE REVIEW API DESIGN METHODOLOGY 1 APACHE CASSANDRA™ OVERVIEW
  • 5. @clunven | @voxxed_lu | #voxxed_lu This is a DISTRIBUTED Database Node • Up to 1TB • 3000 Tx/s/core
  • 6. @clunven | @voxxed_lu | #voxxed_lu …which scale linearly
  • 7. @clunven | @voxxed_lu | #voxxed_lu Data is distributed 0 13 25 38 50 63 75 88 59 (data) RF=2 59 (data) RF=3 replicated
  • 8. @clunven | @voxxed_lu | #voxxed_lu Cassandra is « AP » Consistency Partition Tolerance Availability
  • 9. @clunven | @voxxed_lu | #voxxed_lu Tuneable Consistency RF=3 Client CL=ONECL=QUORUMCL=ALL
  • 10. @clunven | @voxxed_lu | #voxxed_lu …anywhere Cluster Datacenter (Ring)
  • 11. @clunven | @voxxed_lu | #voxxed_lu Sweet spots 1. High Throughput (because we can keep up) 2. High Volume (because we scale linearly and still OLTP) 3. High Availability (replication, masterless) 4. Data distribution (read/write around the globe)
  • 12. @clunven | @voxxed_lu | #voxxed_lu • Le KEYSPACE est comme un schéma dans Oracle, une isolation des données 12 Projet_X Keyspace Une table contient une CLEF PRIMAIRE contenant 2 parties : La partition key et le reste (clustering columns). Chaque valeur de partition key est hashée sous la forme d’un token. Plusieurs lignes avec la même partition key constitue une partition. Data Modelling
  • 13. @clunven | @voxxed_lu | #voxxed_lu • Syntaxe proche du SQL pour les bases relationnelles • Création des objets avec le DDL : • CREATE, INSERT, UPDATE, DELETE, GRANT, REVOKE, SELECT, WHERE 13 Exemple CREATE TABLE market_prices ( symbol TEXT, date TIMESTAMP, price DECIMAL, side INT, PRIMARY KEY (symbol, date) ) WITH CLUSTERING ORDER BY(date DESC); Cassandra Query Language
  • 16. @clunven | @voxxed_lu | #voxxed_lu Reference Application http://killrvideo.github.io
  • 17. @clunven | @voxxed_lu | #voxxed_lu Api Design Methodology 1 killrvideo-dse Drivers DAO3 killrvideo-api-rest killrvideo-api-grpc killrvideo-api-graphql 2
  • 18. @clunven | @voxxed_lu | #voxxed_lu Designing Data Model Entities & Relationships Queries
  • 19. @clunven | @voxxed_lu | #voxxed_lu Conceptual Data Model
  • 20. @clunven | @voxxed_lu | #voxxed_lu Application Workflow R1: Find comments related to target video using its identifier • Get most recent first • Implement Paging R2: Find comments related to target user using its identifier • Get most recent first • Implement Paging R3: Implement CRUD operations
  • 21. @clunven | @voxxed_lu | #voxxed_lu Mapping Q2: Find comments posted for a user with a known id (show most recent first) comments_by_video comments_by_user Q1: Find comments for a video with a known id (show most recent first) Q3: CRUD Operations
  • 22. @clunven | @voxxed_lu | #voxxed_lu Logical Data Model userid creationdate commentid videoid comment comments_by_user K C ↑ videoid creationdate commentid userid comment comments_by_video C ↑ K C ↑ ↑C
  • 23. @clunven | @voxxed_lu | #voxxed_lu Physical Data Model userid commentid videoid comment comments_by_user TIMEUUID K TEXT C UUID UUID ↑ videoid commentid userid comment comments_by_video TIMEUUID K TEXT C UUID UUID ↑
  • 24. @clunven | @voxxed_lu | #voxxed_lu Schema DDL CREATE TABLE IF NOT EXISTS comments_by_user ( userid uuid, commentid timeuuid, videoid uuid, comment text, PRIMARY KEY ((userid), commentid) ) WITH CLUSTERING ORDER BY (commentid DESC); CREATE TABLE IF NOT EXISTS comments_by_video ( videoid uuid, commentid timeuuid, userid uuid, comment text, PRIMARY KEY ((videoid), commentid) ) WITH CLUSTERING ORDER BY (commentid DESC);
  • 25. @clunven | @voxxed_lu | #voxxed_lu How? Conceptual Data Model (Entities, Relations) Application Workflow (Queries) Database Family (Technos +Table)
  • 26.
  • 27. @clunven | @voxxed_lu | #voxxed_lu
  • 28. @clunven | @voxxed_lu | #voxxed_lu
  • 30. @clunven | @voxxed_lu | #voxxed_lu Analysis Criteria 📋 Conceptual Data Model Application Workflow (Queries) Database Family (Technos +Table) Caching Syncvs AsyncReactive SLA (Volume) Data Integrity Filters Paging Sort Latencies Throughput Versionning Confidentiality Atomicity Cardinality Developers 👤 Users/Consumers Language CodeFirst/ Vs SchemaFirst Documentation Test Build Packaging Api Catalog Internalvs Public Techno Profile XP
  • 31. @clunven | @voxxed_lu | #voxxed_lu Analysis Matrix
  • 32. @clunven | @voxxed_lu | #voxxed_lu Decision Tree
  • 33. @clunven | @voxxed_lu | #voxxed_lu  Decoupling Client / Server (Schema on read)  Flexibility: Sync, Async, Reactive + Multi payload  Api Lifecycle (Versioning)  Tooling (API Management, Serverless)  Verbose payloads (json, xml)  No discoverability  Not best fit for command-like (functions) API (RPC)  CRUD superstar  Relevant for OLTP mutations and statuses  Public and web APIs
  • 34. @clunven | @voxxed_lu | #voxxed_lu  High Performances (http/2 – binary serialisation)  Multiple stubs : Sync, Async, Streaming  Multi languages (Interoperability)  Strongly coupled (schema with proto files)  No discoverability  Protobuf serialization format  Distributed network of services (no waits)  High throughput & streaming use cases  Command-like, RPC
  • 35. @clunven | @voxxed_lu | #voxxed_lu  Discoverability, documentation  Custom payloads  Match standards (Json | Http)  Single endpoint (versioning, monitoring, security)  Complex implementation (tooling, still young)  Nice for customers nasty for DB (N+1 select)  BFF : Backend for frontend  Service aggregation | composition (joins)  When bandwidth matters (mobile phones) GraphQL
  • 36. RESOURCES Because COPY/PASTE is the most important skill for developers
  • 37. @clunven | @voxxed_lu | #voxxed_lu References https://github.com/clun/api_Rest_Grpc_GraphQL

Editor's Notes

  1. One of Cassandra's fault-tolerance strategies is replication. Replication is a matter of duplicating data across nodes. The number of replicas is called the Replication Factor. Let’s look at some examples… <click> (RF=1 appears) Let’s start with the simplest example: a replication factor of 1 – only a single copy It’s not something you would likely do in production, but it's a good place to start the discussion. <click> (data appears) Here we’re showing a write request Some data with a partition token of 59 <click> (data moves to node) The top-right node will serve as the coordinator <click> (data turns purple) Notice 59 falls in the purple range <click> (data move to the node) So the coordinator forwards the data to the purple node <click> (data clears) <click> (RF=2 appears) Let's increase the replication factor to 2 <click> (ring colors double) This doubles the range that each node is responsible for. For example, node 75 becomes responsible for the red range and the purple range <click> (data appears) Again our request to write partition with token 59 arrives. But this time the coordinator sends it to two nodes. <click> (data moves) <click> (data fades) Let's increase the replication factor to 3 <click> (RF=3 appears) This means that each node is responsible for 3 ranges <click> (3 ranges appear) Once again, the data arrives at the coordinator Where will the coordinator send the data this time? <click> (data moves) We see the data replicated to all three nodes <click> (data fades) So, in a nutshell, that's how replication works
  2. Consistency level is different than replication factor. On a read, consistency level is how many replicas you read Each replica has a time stamp. The most recent replica wins In this example, imagine we have a replication factor of 3. <click> (shows write arrows) So when we write, we write 3 replicas of the data. <click> (shows CL=ONE) Now let's say we want to read from this cluster with a consistency level of 1. In this case, we only need to read from a single node to resolve the data. <click> (shows read arrows) Now, we can change the consistency level to quorum, <click> (CL=QUORUM appears) Which means we want to read a majority of the replicas. Since the replication factor is 3, quorum implies reading 2 replicas <click> (second read line appears) Notice, if the replicas disagree, the coordinator returns the data with the most recent time stamp <click> (CL clears) We can even specify a consistency level of ALL, <click> (CL=ALL appears) Which means we will read all replicas <click> (third read line appears) (pause to let people absorb)
  3. the default data model in DSE is tabular. It is similar to an RDBMS table but more flexible/dynamic Table is partitioned by one or more columns enabling fast lookups by partition keys A keyspace is the outermost container containing data corresponding to applications, keyspace is similar to database a relational database. each row in a column family is indexed by its key and contains ordered columns. Such unique data model allow DSE to deal with unstructured, schemaless data.
  4. Cassandra Query Language (CQL) is the primary language for communicating with DSE data management platform. CQL is a SQL-like language and allows you to create keyspace and tables, insert and query tables plus other activities using the language you are already familiar with.
  5. ALEXANDRE Few logos: As we already told we are using Java why not using the last Java 12 Services are implemented and connected with Spring Everything is wrapped into a Spring boot 2.1 application Services are exposed as REST with Spring MVC Did you see our gray hairs and beards here, we do Java, we are serious people and do not play with the teenager language JavaScript
  6. ALEXANDRE Show repository, stress its simplicity and blocking calls Show controller, same thing Show controller unit test, run tests