SlideShare uma empresa Scribd logo
1 de 26
Speed up your Apache
Cassandra™ Applications
A Practical Guide to Reactive Programming
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
About us
Cedrick Lunven
Developer Advocate, DataStax
Alexandre Dutra
Software Engineer, DataStax
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Agenda
1
2
3 BACK TO SANITY WITH REACTIVE
LET’S GO ASYNCHRONOUS (AND CRAZY)!
SIMPLE & SYNCHRONOUS
SIMPLE & SYNCHRONOUS
(kiss)
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Apache Cassandra™ Sweet Spots ?
Global
DistributionAlways-On Scalability
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Sample Application Overview
● Time-based events series
CREATE TABLE stock (
symbol text,
value decimal,
date timestamp,
PRIMARY KEY ((symbol), date)
)
WITH CLUSTERING
ORDER BY (date DESC)
AND default_time_to_live = 86400
AND compaction = {
'class' : 'TimeWindowCompactionStrategy’,
'compaction_window_unit' : 'MINUTES',
'compaction_window_size' : '60'
};
v
v
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
DRIVERAPI
Synchronous Stack
CLIENT
12+
© DataStax, All Rights Reserved.Confidential
Demo #1: Sync
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
CLIENT API DRIVER
DseSessionBuilder.build()
Metadata
DseSession
SimpleStatement
session.prepare()
PreparedStatement
Metadata
Initializing
Statements
Connection
API
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
CLIENT API DRIVER
Parameters
SynchronousQueries
PreparedStatement
& Parameters
Bind
Parameters
BoundStatement
ResultSet
ResultSet
Results
Blocked
😴
API
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Sync - SWOT Analysis
Strengths Weaknesses
ThreatsOpportunities
Simple
Easy to Test & Maintain Scalability ⚠️
Blocking 😴
LET’S GO ASYNCHRONOUS
(and crazy !)
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
DRIVERAPI
Asynchronous Stack (Yes,….no changes)
CLIENT
12+
© DataStax, All Rights Reserved.Confidential
Demo #2: Async
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
CLIENT API DRIVER
v
Parameters
AsyncQueries
PreparedStatement
& Parameters Bind
Parameters
BoundStatement
AsyncResultSet
AsyncResultSet
Result
API
CompletionStage
Callback Hell 🔥
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Asynchronous - SWOT Analysis
Strengths Weaknesses
ThreatsOpportunities
Non Blocking
Scalability Maintainability 🤯
Callback Hell 🔥
BACK TO SANITY
(with reactive driver)
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Reactive Manifesto
https://www.reactivemanifesto.org/
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Reactive Streams API
SUBSCRIBER PUBLISHER
subscribe(this)
onSubscribe(subscription)
subscription.request(...)
http://www.reactive-streams.org/
onNext(...)
onComplete()
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
DRIVERAPI
Reactive Stack
CLIENT
12+
© DataStax, All Rights Reserved.Confidential
Demo #3: Reactive
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
CLIENT API DRIVER
v
Parameters
ReactiveQueries
PreparedStatement
& Parameters Bind
Parameters
Row
ReactiveRow
Flux
API
ReactiveResultSet
Subscribe
BoundStatement
Subscriber.onNext
Query execution
onComplete()
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Backpressure
CLIENT DRIVER
Backpressure
❌
CLIENTDRIVER
Backpressure
✅
READ
WRITE
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
Reactive - SWOT Analysis
Strengths Weaknesses
ThreatsOpportunities
Simple & Non Blocking
Scalable & Maintainable OverloadedException
Hard to debug?
© DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved.
References & Questions
THANK YOU

Mais conteúdo relacionado

Mais procurados

RocksDB compaction
RocksDB compactionRocksDB compaction
RocksDB compactionMIJIN AN
 
Storing State Forever: Why It Can Be Good For Your Analytics
Storing State Forever: Why It Can Be Good For Your AnalyticsStoring State Forever: Why It Can Be Good For Your Analytics
Storing State Forever: Why It Can Be Good For Your AnalyticsYaroslav Tkachenko
 
Apache Flink and what it is used for
Apache Flink and what it is used forApache Flink and what it is used for
Apache Flink and what it is used forAljoscha Krettek
 
Streaming SQL with Apache Calcite
Streaming SQL with Apache CalciteStreaming SQL with Apache Calcite
Streaming SQL with Apache CalciteJulian Hyde
 
Spark로 알아보는 빅데이터 처리
Spark로 알아보는 빅데이터 처리Spark로 알아보는 빅데이터 처리
Spark로 알아보는 빅데이터 처리Jeong-gyu Kim
 
Reactive Programming for Real Use Cases
Reactive Programming for Real Use CasesReactive Programming for Real Use Cases
Reactive Programming for Real Use CasesAlex Soto
 
Flink powered stream processing platform at Pinterest
Flink powered stream processing platform at PinterestFlink powered stream processing platform at Pinterest
Flink powered stream processing platform at PinterestFlink Forward
 
Scylla Summit 2022: Making Schema Changes Safe with Raft
Scylla Summit 2022: Making Schema Changes Safe with RaftScylla Summit 2022: Making Schema Changes Safe with Raft
Scylla Summit 2022: Making Schema Changes Safe with RaftScyllaDB
 
Apache Kafka Architecture & Fundamentals Explained
Apache Kafka Architecture & Fundamentals ExplainedApache Kafka Architecture & Fundamentals Explained
Apache Kafka Architecture & Fundamentals Explainedconfluent
 
Parquet performance tuning: the missing guide
Parquet performance tuning: the missing guideParquet performance tuning: the missing guide
Parquet performance tuning: the missing guideRyan Blue
 
Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...
Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...
Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...confluent
 
Consumer offset management in Kafka
Consumer offset management in KafkaConsumer offset management in Kafka
Consumer offset management in KafkaJoel Koshy
 
Understanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage EngineUnderstanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage EngineInfluxData
 
Apache Kafka - Messaging System Overview
Apache Kafka - Messaging System OverviewApache Kafka - Messaging System Overview
Apache Kafka - Messaging System OverviewDmitry Tolpeko
 
Enabling Vectorized Engine in Apache Spark
Enabling Vectorized Engine in Apache SparkEnabling Vectorized Engine in Apache Spark
Enabling Vectorized Engine in Apache SparkKazuaki Ishizaki
 
Deep Dive with Spark Streaming - Tathagata Das - Spark Meetup 2013-06-17
Deep Dive with Spark Streaming - Tathagata  Das - Spark Meetup 2013-06-17Deep Dive with Spark Streaming - Tathagata  Das - Spark Meetup 2013-06-17
Deep Dive with Spark Streaming - Tathagata Das - Spark Meetup 2013-06-17spark-project
 

Mais procurados (20)

Hadoop Map Reduce
Hadoop Map ReduceHadoop Map Reduce
Hadoop Map Reduce
 
RocksDB compaction
RocksDB compactionRocksDB compaction
RocksDB compaction
 
Storing State Forever: Why It Can Be Good For Your Analytics
Storing State Forever: Why It Can Be Good For Your AnalyticsStoring State Forever: Why It Can Be Good For Your Analytics
Storing State Forever: Why It Can Be Good For Your Analytics
 
Apache Flink and what it is used for
Apache Flink and what it is used forApache Flink and what it is used for
Apache Flink and what it is used for
 
Streaming SQL with Apache Calcite
Streaming SQL with Apache CalciteStreaming SQL with Apache Calcite
Streaming SQL with Apache Calcite
 
Spark로 알아보는 빅데이터 처리
Spark로 알아보는 빅데이터 처리Spark로 알아보는 빅데이터 처리
Spark로 알아보는 빅데이터 처리
 
Reactive Programming for Real Use Cases
Reactive Programming for Real Use CasesReactive Programming for Real Use Cases
Reactive Programming for Real Use Cases
 
Introduction to influx db
Introduction to influx dbIntroduction to influx db
Introduction to influx db
 
Druid
DruidDruid
Druid
 
Flink powered stream processing platform at Pinterest
Flink powered stream processing platform at PinterestFlink powered stream processing platform at Pinterest
Flink powered stream processing platform at Pinterest
 
Scylla Summit 2022: Making Schema Changes Safe with Raft
Scylla Summit 2022: Making Schema Changes Safe with RaftScylla Summit 2022: Making Schema Changes Safe with Raft
Scylla Summit 2022: Making Schema Changes Safe with Raft
 
Apache Kafka Architecture & Fundamentals Explained
Apache Kafka Architecture & Fundamentals ExplainedApache Kafka Architecture & Fundamentals Explained
Apache Kafka Architecture & Fundamentals Explained
 
Parquet performance tuning: the missing guide
Parquet performance tuning: the missing guideParquet performance tuning: the missing guide
Parquet performance tuning: the missing guide
 
Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...
Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...
Troubleshooting as Your Kafka Clusters Grow (Krunal Vora, Tinder) Kafka Summi...
 
Consumer offset management in Kafka
Consumer offset management in KafkaConsumer offset management in Kafka
Consumer offset management in Kafka
 
Apache kafka
Apache kafkaApache kafka
Apache kafka
 
Understanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage EngineUnderstanding InfluxDB’s New Storage Engine
Understanding InfluxDB’s New Storage Engine
 
Apache Kafka - Messaging System Overview
Apache Kafka - Messaging System OverviewApache Kafka - Messaging System Overview
Apache Kafka - Messaging System Overview
 
Enabling Vectorized Engine in Apache Spark
Enabling Vectorized Engine in Apache SparkEnabling Vectorized Engine in Apache Spark
Enabling Vectorized Engine in Apache Spark
 
Deep Dive with Spark Streaming - Tathagata Das - Spark Meetup 2013-06-17
Deep Dive with Spark Streaming - Tathagata  Das - Spark Meetup 2013-06-17Deep Dive with Spark Streaming - Tathagata  Das - Spark Meetup 2013-06-17
Deep Dive with Spark Streaming - Tathagata Das - Spark Meetup 2013-06-17
 

Semelhante a Reactive Programming with Cassandra

Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...
Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...
Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...Matt Stubbs
 
Real time data pipeline with spark streaming and cassandra with mesos
Real time data pipeline with spark streaming and cassandra with mesosReal time data pipeline with spark streaming and cassandra with mesos
Real time data pipeline with spark streaming and cassandra with mesosRahul Kumar
 
Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...
Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...
Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...DataStax
 
Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...
Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...
Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...DataStax
 
Live traffic capture and replay in cassandra 4.0
Live traffic capture and replay in cassandra 4.0Live traffic capture and replay in cassandra 4.0
Live traffic capture and replay in cassandra 4.0Vinay Kumar Chella
 
Oracle RAC 12c Rel. 2 for Continuous Availability
Oracle RAC 12c Rel. 2 for Continuous AvailabilityOracle RAC 12c Rel. 2 for Continuous Availability
Oracle RAC 12c Rel. 2 for Continuous AvailabilityMarkus Michalewicz
 
implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...Joseph Arriola
 
Reporting from the Trenches: Intuit & Cassandra
Reporting from the Trenches: Intuit & CassandraReporting from the Trenches: Intuit & Cassandra
Reporting from the Trenches: Intuit & CassandraDataStax
 
Webinar: Comparing DataStax Enterprise with Open Source Apache Cassandra
Webinar: Comparing DataStax Enterprise with Open Source Apache CassandraWebinar: Comparing DataStax Enterprise with Open Source Apache Cassandra
Webinar: Comparing DataStax Enterprise with Open Source Apache CassandraDataStax
 
Xanadu Big Data Platform Technology Introduction
Xanadu Big Data Platform Technology IntroductionXanadu Big Data Platform Technology Introduction
Xanadu Big Data Platform Technology IntroductionAlex G. Lee, Ph.D. Esq. CLP
 
Reactive IoT, Java One 2016
Reactive IoT, Java One 2016Reactive IoT, Java One 2016
Reactive IoT, Java One 2016Kynetics
 
Big Data Analytics with Spark
Big Data Analytics with SparkBig Data Analytics with Spark
Big Data Analytics with SparkDataStax Academy
 
Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...
Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...
Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...DataStax
 
Webinar: DataStax Managed Cloud: focus on innovation, not administration
Webinar:  DataStax Managed Cloud: focus on innovation, not administrationWebinar:  DataStax Managed Cloud: focus on innovation, not administration
Webinar: DataStax Managed Cloud: focus on innovation, not administrationDataStax
 
Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...
Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...
Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...DataStax
 
Spark Summit EU talk by Debasish Das and Pramod Narasimha
Spark Summit EU talk by Debasish Das and Pramod NarasimhaSpark Summit EU talk by Debasish Das and Pramod Narasimha
Spark Summit EU talk by Debasish Das and Pramod NarasimhaSpark Summit
 
Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...
Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...
Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...DataStax
 

Semelhante a Reactive Programming with Cassandra (20)

Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...
Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...
Speed Up Your Apache Cassandra™ Applications: A Practical Guide to Reactive P...
 
Real time data pipeline with spark streaming and cassandra with mesos
Real time data pipeline with spark streaming and cassandra with mesosReal time data pipeline with spark streaming and cassandra with mesos
Real time data pipeline with spark streaming and cassandra with mesos
 
Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...
Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...
Realtime Data Pipeline with Spark Streaming and Cassandra with Mesos (Rahul K...
 
Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...
Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...
Webinar: DataStax Enterprise 6: 10 Ways to Multiply the Power of Apache Cassa...
 
Live traffic capture and replay in cassandra 4.0
Live traffic capture and replay in cassandra 4.0Live traffic capture and replay in cassandra 4.0
Live traffic capture and replay in cassandra 4.0
 
Oracle RAC 12c Rel. 2 for Continuous Availability
Oracle RAC 12c Rel. 2 for Continuous AvailabilityOracle RAC 12c Rel. 2 for Continuous Availability
Oracle RAC 12c Rel. 2 for Continuous Availability
 
implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...
 
Reporting from the Trenches: Intuit & Cassandra
Reporting from the Trenches: Intuit & CassandraReporting from the Trenches: Intuit & Cassandra
Reporting from the Trenches: Intuit & Cassandra
 
Webinar: Comparing DataStax Enterprise with Open Source Apache Cassandra
Webinar: Comparing DataStax Enterprise with Open Source Apache CassandraWebinar: Comparing DataStax Enterprise with Open Source Apache Cassandra
Webinar: Comparing DataStax Enterprise with Open Source Apache Cassandra
 
Xanadu Big Data Platform Technology Introduction
Xanadu Big Data Platform Technology IntroductionXanadu Big Data Platform Technology Introduction
Xanadu Big Data Platform Technology Introduction
 
Reactive IoT, Java One 2016
Reactive IoT, Java One 2016Reactive IoT, Java One 2016
Reactive IoT, Java One 2016
 
Big Data Analytics with Spark
Big Data Analytics with SparkBig Data Analytics with Spark
Big Data Analytics with Spark
 
Silicon Valley Workshop: Xanadu introduction
Silicon Valley Workshop: Xanadu introduction Silicon Valley Workshop: Xanadu introduction
Silicon Valley Workshop: Xanadu introduction
 
Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...
Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...
Designing Fault-Tolerant Applications with DataStax Enterprise and Apache Cas...
 
Webinar: DataStax Managed Cloud: focus on innovation, not administration
Webinar:  DataStax Managed Cloud: focus on innovation, not administrationWebinar:  DataStax Managed Cloud: focus on innovation, not administration
Webinar: DataStax Managed Cloud: focus on innovation, not administration
 
Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...
Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...
Webinar - The Agility Challenge - Powering Cloud Apps with Multi-Model & Mixe...
 
Spark Summit EU talk by Debasish Das and Pramod Narasimha
Spark Summit EU talk by Debasish Das and Pramod NarasimhaSpark Summit EU talk by Debasish Das and Pramod Narasimha
Spark Summit EU talk by Debasish Das and Pramod Narasimha
 
DataStax 6 and Beyond
DataStax 6 and BeyondDataStax 6 and Beyond
DataStax 6 and Beyond
 
Cloud applications
Cloud applicationsCloud applications
Cloud applications
 
Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...
Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...
Webinar: The Performance Challenge: Providing an Amazing Customer Experience ...
 

Mais de 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.pdfCé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 graphQLCé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 cassandraCé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 icroservicesCédrick Lunven
 
VoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4JVoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4JCédrick Lunven
 
VoxxedDays Luxembourg 2019
VoxxedDays Luxembourg 2019VoxxedDays Luxembourg 2019
VoxxedDays Luxembourg 2019Cédrick Lunven
 
Create API for your Databases
Create API for your DatabasesCreate API for your Databases
Create API for your DatabasesCé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
 
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 CassandraCédrick Lunven
 
Riviera jug apicassandra
Riviera jug apicassandraRiviera jug apicassandra
Riviera jug apicassandraCé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 JhipsterCédrick Lunven
 
Introduction to Feature Toggle and FF4J
Introduction to Feature Toggle and FF4JIntroduction to Feature Toggle and FF4J
Introduction to Feature Toggle and FF4JCédrick Lunven
 

Mais de Cédrick Lunven (19)

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
 
Shift Dev Conf API
Shift Dev Conf APIShift Dev Conf API
Shift Dev Conf API
 
VoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4JVoxxedDays Luxembourg FF4J
VoxxedDays Luxembourg FF4J
 
VoxxedDays Luxembourg 2019
VoxxedDays Luxembourg 2019VoxxedDays Luxembourg 2019
VoxxedDays Luxembourg 2019
 
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...
 
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
 
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
 

Último

What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DayH2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DaySri Ambati
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 

Último (20)

What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo DayH2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
H2O.ai CEO/Founder: Sri Ambati Keynote at Wells Fargo Day
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 

Reactive Programming with Cassandra

  • 1. Speed up your Apache Cassandra™ Applications A Practical Guide to Reactive Programming
  • 2. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. About us Cedrick Lunven Developer Advocate, DataStax Alexandre Dutra Software Engineer, DataStax
  • 3. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Agenda 1 2 3 BACK TO SANITY WITH REACTIVE LET’S GO ASYNCHRONOUS (AND CRAZY)! SIMPLE & SYNCHRONOUS
  • 5. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Apache Cassandra™ Sweet Spots ? Global DistributionAlways-On Scalability
  • 6. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Sample Application Overview ● Time-based events series CREATE TABLE stock ( symbol text, value decimal, date timestamp, PRIMARY KEY ((symbol), date) ) WITH CLUSTERING ORDER BY (date DESC) AND default_time_to_live = 86400 AND compaction = { 'class' : 'TimeWindowCompactionStrategy’, 'compaction_window_unit' : 'MINUTES', 'compaction_window_size' : '60' }; v v
  • 7. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. DRIVERAPI Synchronous Stack CLIENT 12+
  • 8. © DataStax, All Rights Reserved.Confidential Demo #1: Sync
  • 9. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. CLIENT API DRIVER DseSessionBuilder.build() Metadata DseSession SimpleStatement session.prepare() PreparedStatement Metadata Initializing Statements Connection API
  • 10. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. CLIENT API DRIVER Parameters SynchronousQueries PreparedStatement & Parameters Bind Parameters BoundStatement ResultSet ResultSet Results Blocked 😴 API
  • 11. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Sync - SWOT Analysis Strengths Weaknesses ThreatsOpportunities Simple Easy to Test & Maintain Scalability ⚠️ Blocking 😴
  • 13. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. DRIVERAPI Asynchronous Stack (Yes,….no changes) CLIENT 12+
  • 14. © DataStax, All Rights Reserved.Confidential Demo #2: Async
  • 15. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. CLIENT API DRIVER v Parameters AsyncQueries PreparedStatement & Parameters Bind Parameters BoundStatement AsyncResultSet AsyncResultSet Result API CompletionStage Callback Hell 🔥
  • 16. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Asynchronous - SWOT Analysis Strengths Weaknesses ThreatsOpportunities Non Blocking Scalability Maintainability 🤯 Callback Hell 🔥
  • 17. BACK TO SANITY (with reactive driver)
  • 18. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Reactive Manifesto https://www.reactivemanifesto.org/
  • 19. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Reactive Streams API SUBSCRIBER PUBLISHER subscribe(this) onSubscribe(subscription) subscription.request(...) http://www.reactive-streams.org/ onNext(...) onComplete()
  • 20. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. DRIVERAPI Reactive Stack CLIENT 12+
  • 21. © DataStax, All Rights Reserved.Confidential Demo #3: Reactive
  • 22. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. CLIENT API DRIVER v Parameters ReactiveQueries PreparedStatement & Parameters Bind Parameters Row ReactiveRow Flux API ReactiveResultSet Subscribe BoundStatement Subscriber.onNext Query execution onComplete()
  • 23. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Backpressure CLIENT DRIVER Backpressure ❌ CLIENTDRIVER Backpressure ✅ READ WRITE
  • 24. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. Reactive - SWOT Analysis Strengths Weaknesses ThreatsOpportunities Simple & Non Blocking Scalable & Maintainable OverloadedException Hard to debug?
  • 25. © DataStax, All Rights Reserved.ConfidentialConfidential © DataStax, All Rights Reserved. References & Questions

Notas do Editor

  1. CEDRICK Good Afternoon We are going to speak you about Software Development and ways to speed-up your applications. But before starting I would like to ask you a few questions: (1) Who is already familiar with JAVA programming language Ok, so YOU are allowed to stay in the room. Who said Java is no more the most popular language ? It is. full disclosure, during this presentation you will see some Java code, you will probably to try it it afterward Ok so Question 2 : (2) Who is currently using or has used the DataStax Java driver for Apache Cassandra, OSS or DSE : nevermind Oh so many ? Alexs, we are probably giving talk in the correct conference then. Good. That what we expected. (3) And final question the hardest, who has already tested the new generation drivers releases this year ? Not so many, again not a surprise this is rather new. You are in the good room, we are gonna do our presentation with the new driver and you will see the differences. CLICK
  2. CEDRICK I am Cedrick Lunven, Developer Advocate at DataStax. My job is to produce tons of contents for you to succeed with your Apache Cassandra projects : Academy.datastax.com : VIDEO Trainings, blogposts Getting Started all sort of Tutorials VIDEOS : DDS videos weekly and all recorded meetup we are doing, TWICH A Twitch Channel with stream and live coding every week CODE : References applications and sample codes And I am with Alexandre Dutra. ALEXANDRE I am Alexandre Dutra, Technical Manager & Software Engineer working for DataStax since 2015. I am one of the main contributors of the DataStax Java driver for Apache Cassandra and DSE, and I am also the author of the new Reactive API introduced in the latest release of the DSE driver this year. I am a big fan of reactive programming and have been using reactive programming for a while now, not only in the driver but also in other products that we develop at DataStax, such as the DataStax Bulk Loader. For now I will Cedrick set the scene and I will come back from demos
  3. CEDRICK In this session we will work with a sample service, sample API. We will first present the first in a synchronous process model. From then, we will move to ASYNCHRONOUS processing model and then Reactive mode. Let’s get started !
  4. So we need a sample use case for our API fitting Apache Cassandra strengths. Imagine, If you would have to explain why Cassandra is so cool to someone that has been working with SGBD his all life and you get 2 min what would you say ? As advocate this is part of my job so why I like to say is : This is a distribute Databases, multiple nodes there is no real sense to use only one Data is distributed among those nodes but also replicated : that means you can loose some node you don’t loose data, BTYW you can loose any node because there is no master In a mode let’s have this abacus 1TB of data and 3000 transaction and per core, if you need more volume add more nodes, if you need more throughput add more nodes So what are use cases for Cassandra : Data resiliency Gobal distribution read/write anywhere and it is replicated HUGE volume and still real time queries Very high throughput And this is a …CLICK
  5. CEDRICK We chose a Time based event series aka Timeseries and thus for 2 main reasons : One : The use case fits very well Apache Cassandra : High Throughput, heavy writes, lot of volumes, need scalability Two Aleks : (joking) is because we are always using the same sample Me : No ! Come on. Two Because the data model is simple yet interesting. <CLICK> As you imagine we define the partition key as the source of events to evenly distributed events among the nodes <CLICK> We designed a valueDate as a Clustering Columns to search easily and graph some charts <CLICK> We specified DESC to get the last item first, those are the one we want to display. <CLICK> No bucketing so let’s define a TTL to 24H to avoid too large partitions <CLICK> And time series would use TWCS limit SSTABLE number <CLICK> Because, just have a look to what we are trying to draw ALEXANDRE But let’s keep things simple and stupid KISS.
  6. 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
  7. CEDRICK So this is the sequence diagram we will show again and again to understand what happened under the hood Client can UI or any system invoking our service API is our interface, the way we expose the service Driver represents the Java Driver API and Driver compose your backend application runtime, real stuff and not javascript for teenagers And the eye, well I am pretty usre you can guess During application start first operation executed is Connection <CLICK> And, still in the initializing phase we prepare the statements <CLICK> Those operations are, and will remain, synchronous everytime. We won’t show that to you again in the next scenarii But what about the real Crud OPERATIONS ? Let’s start with the mutations. <CLICK>
  8. CEDRICK Create and Delete operations follow the same pattern, they just don’t produce the same return codes, http codes. 201 for the first and 204 for the other. <CLICK> I am decoding here. Client send parameters to the API which will validate those, Joking : YOU are responsible for the parameters, no excuses. JavaNullPointerException is YOUR fault. <CLICK> API will use the params to create a Statement Those are binded together at the driver level to create a BoundStatement <CLICK> Execution is trigger and you get a status, but no records this is CREATE and DELETE Then you propagate status up to the client, success or exception <CLICK> Again, we are waiting like hell This is it for the synchronous mutations, what about the queries ?
  9. ALEXANDRE Exactly same thing as before
  10. In the most general sense reactive programming is a programming paradigm that allows to create responsive and resilient systems for processing data. These ideas have been summarized in the Reactive Manifesto. The manifesto stresses 4 key characristics: Responsiveness: The system always responds in a timely manner. Resilience: The system stays responsive in the face of failure. Elasticity: The system stays responsive under varying workload and adapts itself to variable ingestion rates. Message Driven: the system relies on asynchronous messaging to achieve loose coupling, and isolation.
  11. But usually when we refer to Reactive Programming we refer to the Reactive Streams initiative. This is a working group of people that created an API that allows you to build reactive systems in many programming languages, including Java. This initiative provides you with a Specification, an API and a TCK (Test Compatibility Kit). The TCK allows you to certify that your implementation is compliant with the API requirements. The API defines a few roles like the Publisher (the guy who emits data), the Subscriber (the guy who receives data) and the Subscription which defines the contract between a publisher and a subscriber.
  12. 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 NEW: Spring Web Flux + Reactor NEW: Driver reactive API
  13. Those operation are and will remain synchronous Do it at the application launch
  14. Let’s talk a bit about backpressure. Backpressure is a key notion in reactive streams; it’s a mechanism that allows the publisher and the subscriber to agree on an acceptable throughput for both, in order to avoid overwhelming the system with more messages than it can handle. The driver is capable of communicating backpressure between your application and the remote DSE server in some situations only, namely when the server acts like a Publisher and your application acts as a subscriber. – IOW when you are reading data from the server In this case, the driver will only fetch more results if the subscriber is ready to process them. The opposite situation is trickier: if you are writing data to DES, then your application is acting like a Publisher, and it’s your responsibility to regulate your throughput in order to avoid overwhelming the cluster. This is because the Cassandra protocol does not allow the server to communicate backpressure to a client. So if you don’t regulate your data ingestion rate, you risk getting back an OverloadedException. https://issues.apache.org/jira/browse/CASSANDRA-7937 Apply backpressure gently when overloaded with writes https://issues.apache.org/jira/browse/CASSANDRA-10993 Make read and write requests paths fully non-blocking, eliminate related stages (TPC for OSS Cassandra), slated for 4.x
  15. Hard to debug: but there are tools to help, see the chapter on debugging for Reactor: https://projectreactor.io/docs/core/snapshot/reference/#debugging