SlideShare une entreprise Scribd logo
1  sur  36
Télécharger pour lire hors ligne
Apache Flink
Vue d’ensemble du framework
Paris Spark Meetup
07/12/2015
Bilal BALTAGI
@Bilal_baltagi
Plan
● Introduction à Apache Flink
● L'écosystème Apache Flink
● Que fournit Apache Flink
○ Batch
○ Streaming
○ FlinkML et Gelly
● Apache Flink overview
2
Introduction à Apache Flink
● Open-source Big Data Analytics Framework
● Conçu dès le départ pour :
○ In-memory process
○ Traitement en streaming
○ Nativement itérative
○ Mémoire autogérée
○ Optimisation basée sur le coût
3
Introduction à Apache Flink
● Origine :
○ Stratosphere : Projet universitaire
○ Né à Berlin en 2008
● Quelques dates :
○ Avril 2014 : Apache Projet Incubation
○ Décembre 2014 : Apache Projet Top level
○ Novembre 2015 : Dernière release 0.10.1
4
Écosystème classique d’un Big data analytics framework
5
6
Que fournis Apache Flink
● Moteur d'exécution : Distribué et évolutif
● Plusieurs API :
○ DataSet - Batch (Java, Scala et Python)
○ DataStream - temps réel (Java et Scala)
○ Table - Batch et temps réel (≈Relational SQL)
7
Que fournis Apache Flink
● Domain-specific library (DSL) :
○ FlinkML : Machine Learning
○ Gelly : Traitement des graphes
8
Actuellement le seul framework Open-
source hybride :
Batch and True Real Time
9
Apache Flink : Traitement Batch
● Cost-based optimisation du plan d'exécution
○ En fonction du contexte (Single machine,
cluster…)
○ En fonction de la volumétrie des données
sources
10
Apache Flink : Traitement Batch - plan d’execution
11
Apache Flink : Traitement Batch - plan d’execution
12
Apache Flink : Traitement Batch
● Flink gère sa propre mémoire :
○ Pas de Out-of-memory
○ Réduction du Garbage collector
○ Stabilité
13
Apache Flink : Traitement Batch
case class Word (word: String, frequency: Int)
val lines: DataSet[String] = env.fromElements( "O Romeo,
Romeo! wherefore art thou Romeo?”, …)
lines.flatMap {line => line.split(" ")
.map(word => Word(word,1))}
.groupBy("word")
.sum("frequency")
.print()
14
Apache Flink : Traitement Batch - comparaison
TeraSort de 3,2To - 80Go/node
Source : http://goo.gl/IqR97G 15
Apache Flink : Traitement Batch - comparaison
HashJoin - 10 Noeud - 256Mo + 240Go
Source : http://goo.gl/IqR97G 16
4X Plus rapide que Spark
17
Apache Flink : Traitement temps réel
● N’est plus en bêta depuis le 23/11/2015
● Low-latency : temps réel
● High throughput : Volumétrie élevée
● Fault-tolerance Exactly-once : Pas de traitement
dupliqué
18
Apache Flink : Traitement temps réel
● Traitement native des itérations
● API riche :
○ Connecteurs (Flume, kafka, Twitter…)
○ Opérations identiques au batch
19
Apache Flink : Traitement temps réel
● Quelques cas ou le “vrai temps réel” est critique :
○ Détection des fraudes et anomalies
○ Gestion des trafics
○ Recommandation en ligne
Source : http://spark.apache.org/faq.html 20
Apache Flink : Traitement temps réel
Storm Vs. Flink
Source : http://goo.gl/1Tgbn3 21
260X Plus de données que Storm
22
Apache Flink : Traitement temps réel
● Exemple de traitement d’un flux continu avec Apache Flink : http://flink.
apache.org/news/2015/12/04/Introducing-windows.html
Capteur : Nombre de véhicules
23
Apache Flink : Traitement temps réel
Rolling sum : Retourne en continue la somme du nombre de
véhicules passés 24
Apache Flink : Traitement temps réel
Tumbling windows: Retourne toutes les 60 secondes le
nombre de véhicules qui viennent de passer 25
Apache Flink : Traitement temps réel
Windows sliding : Retourne toutes les 30 secondes le nombre
de véhicules qui sont passés au cours des 60 dernières
secondes 26
Apache Flink : Traitement temps réel
case class Word (word: String, frequency: Int)
val lines: DataStream[String] = env.fromSocketStream(...)
lines.flatMap {line => line.split(" ")
.map(word => Word(word,1))}
.window(Time.of(5,SECONDS)).every(Time.of(1,SECONDS))
.groupBy("word").sum("frequency")
.print()
27
Apache Flink : FlinkML
● FlinkML : Machine learning
● Inspiré de
○ Sikit-learn : Spécification propre des
pipelines ML
○ Spark’s MLLIB : Alogrithmes scalables
28
Apache Flink : Gelly
● Gelly : Traitement des graphes
29
Apache Flink : FlinkML et Gelly
● Points forts :
○ In-memory data streaming
○ Code identique entre machine locale (extrait
des données) et cluster (toutes les données)
○ Traitement nativement itérative
■ Iteration
■ Delta-iteration
30
Apache Flink : FlinkML et Gelly
● Algorithmes avec itérations :
○ K-means
○ PageRank
31
Apache Flink : Overview
Real-time Stream
Cyclic Batch
Machine Learning
Graph
32
Apache Flink : overview - qui utilise Flink ?
33
Flink 1.0 - Projet en cours...
● FlinkML streaming
● Sortir Table SQL de la bêta
● D’autres connecteurs
34
Flink : Pour aller plus loin
Site officiel : https://flink.apache.org/
Training : http://dataartisans.github.io/flink-training/
Gartner : http://goo.gl/mlgMoI
KDnuggets : http://goo.gl/Z9hRvn
Apache Flink vue par un développeur Spark : http://goo.
gl/pygDyV
35
Gardons contact
● https://www.linkedin.com/in/BilalBaltagi
● bilal.baltagi@gmail.com
● @bilal_baltagi
http://www.meetup.com/fr/Paris-Apache-Flink-Meetup/
36

Contenu connexe

Tendances

Business Intelligence : introduction to datawarehouse
Business Intelligence : introduction to datawarehouseBusiness Intelligence : introduction to datawarehouse
Business Intelligence : introduction to datawarehouse
Alexandre Equoy
 

Tendances (20)

BigData_Chp4: NOSQL
BigData_Chp4: NOSQLBigData_Chp4: NOSQL
BigData_Chp4: NOSQL
 
BigData_TP3 : Spark
BigData_TP3 : SparkBigData_TP3 : Spark
BigData_TP3 : Spark
 
Thinking big
Thinking bigThinking big
Thinking big
 
Cours Big Data Chap1
Cours Big Data Chap1Cours Big Data Chap1
Cours Big Data Chap1
 
Les BD NoSQL
Les BD NoSQLLes BD NoSQL
Les BD NoSQL
 
Thinking Big - Big data: principes et architecture
Thinking Big - Big data: principes et architecture Thinking Big - Big data: principes et architecture
Thinking Big - Big data: principes et architecture
 
Hadoop et son écosystème
Hadoop et son écosystèmeHadoop et son écosystème
Hadoop et son écosystème
 
Thinking BIG
Thinking BIGThinking BIG
Thinking BIG
 
Spark (v1.3) - Présentation (Français)
Spark (v1.3) - Présentation (Français)Spark (v1.3) - Présentation (Français)
Spark (v1.3) - Présentation (Français)
 
Business Intelligence : introduction to datawarehouse
Business Intelligence : introduction to datawarehouseBusiness Intelligence : introduction to datawarehouse
Business Intelligence : introduction to datawarehouse
 
Data warehouse
Data warehouseData warehouse
Data warehouse
 
Cours Big Data Chap2
Cours Big Data Chap2Cours Big Data Chap2
Cours Big Data Chap2
 
BigData_TP5 : Neo4J
BigData_TP5 : Neo4JBigData_TP5 : Neo4J
BigData_TP5 : Neo4J
 
Chp2 - Les Entrepôts de Données
Chp2 - Les Entrepôts de DonnéesChp2 - Les Entrepôts de Données
Chp2 - Les Entrepôts de Données
 
Base de données graphe, Noe4j concepts et mise en oeuvre
Base de données graphe, Noe4j concepts et mise en oeuvreBase de données graphe, Noe4j concepts et mise en oeuvre
Base de données graphe, Noe4j concepts et mise en oeuvre
 
BigData_Chp2: Hadoop & Map-Reduce
BigData_Chp2: Hadoop & Map-ReduceBigData_Chp2: Hadoop & Map-Reduce
BigData_Chp2: Hadoop & Map-Reduce
 
Hive ppt (1)
Hive ppt (1)Hive ppt (1)
Hive ppt (1)
 
Partie1BI-DW2019
Partie1BI-DW2019Partie1BI-DW2019
Partie1BI-DW2019
 
Partie3BI-DW-OLAP2019
Partie3BI-DW-OLAP2019Partie3BI-DW-OLAP2019
Partie3BI-DW-OLAP2019
 
Cours Big Data Chap5
Cours Big Data Chap5Cours Big Data Chap5
Cours Big Data Chap5
 

En vedette

En vedette (20)

Apache SPARK ML : principes, concepts et mise en œuvre
Apache SPARK  ML : principes, concepts et  mise en œuvre Apache SPARK  ML : principes, concepts et  mise en œuvre
Apache SPARK ML : principes, concepts et mise en œuvre
 
CDAP, la boîte à outil pour concevoir vos applications Big Data
CDAP,  la boîte à outil pour concevoir vos applications Big DataCDAP,  la boîte à outil pour concevoir vos applications Big Data
CDAP, la boîte à outil pour concevoir vos applications Big Data
 
Hadoop meetup : HUGFR Construire le cluster le plus rapide pour l'analyse des...
Hadoop meetup : HUGFR Construire le cluster le plus rapide pour l'analyse des...Hadoop meetup : HUGFR Construire le cluster le plus rapide pour l'analyse des...
Hadoop meetup : HUGFR Construire le cluster le plus rapide pour l'analyse des...
 
Introduction spark
Introduction sparkIntroduction spark
Introduction 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...
 
Spark RDD : Transformations & Actions
Spark RDD : Transformations & ActionsSpark RDD : Transformations & Actions
Spark RDD : Transformations & Actions
 
Spark, ou comment traiter des données à la vitesse de l'éclair
Spark, ou comment traiter des données à la vitesse de l'éclairSpark, ou comment traiter des données à la vitesse de l'éclair
Spark, ou comment traiter des données à la vitesse de l'éclair
 
Apache Storm - Introduction au traitement temps-réel avec Storm
Apache Storm - Introduction au traitement temps-réel avec StormApache Storm - Introduction au traitement temps-réel avec Storm
Apache Storm - Introduction au traitement temps-réel avec Storm
 
Introduction to Apache Flink
Introduction to Apache FlinkIntroduction to Apache Flink
Introduction to Apache Flink
 
Off-heaping the Apache HBase Read Path
Off-heaping the Apache HBase Read Path Off-heaping the Apache HBase Read Path
Off-heaping the Apache HBase Read Path
 
BigData_TP2: Design Patterns dans Hadoop
BigData_TP2: Design Patterns dans HadoopBigData_TP2: Design Patterns dans Hadoop
BigData_TP2: Design Patterns dans Hadoop
 
BigData_TP4 : Cassandra
BigData_TP4 : CassandraBigData_TP4 : Cassandra
BigData_TP4 : Cassandra
 
BigData_TP1: Initiation à Hadoop et Map-Reduce
BigData_TP1: Initiation à Hadoop et Map-ReduceBigData_TP1: Initiation à Hadoop et Map-Reduce
BigData_TP1: Initiation à Hadoop et Map-Reduce
 
BigData_Chp3: Data Processing
BigData_Chp3: Data ProcessingBigData_Chp3: Data Processing
BigData_Chp3: Data Processing
 
Software Engineering - chp8- deployment
Software Engineering - chp8- deploymentSoftware Engineering - chp8- deployment
Software Engineering - chp8- deployment
 
Building a Modern Data Architecture with Enterprise Hadoop
Building a Modern Data Architecture with Enterprise HadoopBuilding a Modern Data Architecture with Enterprise Hadoop
Building a Modern Data Architecture with Enterprise Hadoop
 
Analysis-of-Major-Trends-in-big-data-analytics-slim-baltagi-hadoop-summit
Analysis-of-Major-Trends-in-big-data-analytics-slim-baltagi-hadoop-summitAnalysis-of-Major-Trends-in-big-data-analytics-slim-baltagi-hadoop-summit
Analysis-of-Major-Trends-in-big-data-analytics-slim-baltagi-hadoop-summit
 
Step-by-Step Introduction to Apache Flink
Step-by-Step Introduction to Apache Flink Step-by-Step Introduction to Apache Flink
Step-by-Step Introduction to Apache Flink
 
A Multi Colored YARN
A Multi Colored YARNA Multi Colored YARN
A Multi Colored YARN
 
Monitoring applicatif : Pourquoi et comment ?
Monitoring applicatif : Pourquoi et comment ?Monitoring applicatif : Pourquoi et comment ?
Monitoring applicatif : Pourquoi et comment ?
 

Similaire à Apache Flink par Bilal Baltagi Paris Spark Meetup Dec 2015

Ingénierie de la performance au sein des mégadonnées
Ingénierie de la performance au sein des mégadonnéesIngénierie de la performance au sein des mégadonnées
Ingénierie de la performance au sein des mégadonnées
Daniel Lemire
 
Gestion_d_un_projet_Web_e_commerce_Piece (1).pdf
Gestion_d_un_projet_Web_e_commerce_Piece (1).pdfGestion_d_un_projet_Web_e_commerce_Piece (1).pdf
Gestion_d_un_projet_Web_e_commerce_Piece (1).pdf
SofianeHassine2
 
Gestion_d_un_projet_Web_e_commerce_Piece.pdf
Gestion_d_un_projet_Web_e_commerce_Piece.pdfGestion_d_un_projet_Web_e_commerce_Piece.pdf
Gestion_d_un_projet_Web_e_commerce_Piece.pdf
SofianeHassine2
 

Similaire à Apache Flink par Bilal Baltagi Paris Spark Meetup Dec 2015 (20)

Monitoring d'applications/environnements PHP : APM et Pinba
Monitoring d'applications/environnements PHP : APM et PinbaMonitoring d'applications/environnements PHP : APM et Pinba
Monitoring d'applications/environnements PHP : APM et Pinba
 
Big Data Viz (and much more!) with Apache Zeppelin
Big Data Viz (and much more!) with Apache ZeppelinBig Data Viz (and much more!) with Apache Zeppelin
Big Data Viz (and much more!) with Apache Zeppelin
 
Apache kafka big data track
Apache kafka   big data trackApache kafka   big data track
Apache kafka big data track
 
Apache Kafka, Un système distribué de messagerie hautement performant
Apache Kafka, Un système distribué de messagerie hautement performantApache Kafka, Un système distribué de messagerie hautement performant
Apache Kafka, Un système distribué de messagerie hautement performant
 
S2-01-PHP.pptx
S2-01-PHP.pptxS2-01-PHP.pptx
S2-01-PHP.pptx
 
Monitoring d'applications/environnements PHP: APM et Pinba
Monitoring d'applications/environnements PHP: APM et PinbaMonitoring d'applications/environnements PHP: APM et Pinba
Monitoring d'applications/environnements PHP: APM et Pinba
 
LLVM, clang & c++
LLVM, clang & c++LLVM, clang & c++
LLVM, clang & c++
 
Chap 3 - ASP .Net.pptx
Chap 3 - ASP .Net.pptxChap 3 - ASP .Net.pptx
Chap 3 - ASP .Net.pptx
 
Stream processing et SQL
Stream processing et SQLStream processing et SQL
Stream processing et SQL
 
Ingénierie de la performance au sein des mégadonnées
Ingénierie de la performance au sein des mégadonnéesIngénierie de la performance au sein des mégadonnées
Ingénierie de la performance au sein des mégadonnées
 
Hi-Media Couchbase meetup Paris Nb #1
Hi-Media Couchbase meetup Paris Nb #1Hi-Media Couchbase meetup Paris Nb #1
Hi-Media Couchbase meetup Paris Nb #1
 
Explorez vos données présentes dans MongoDB avec Apache Zeppelin
Explorez vos données présentes dans MongoDB avec Apache ZeppelinExplorez vos données présentes dans MongoDB avec Apache Zeppelin
Explorez vos données présentes dans MongoDB avec Apache Zeppelin
 
Gestion_d_un_projet_Web_e_commerce_Piece (1).pdf
Gestion_d_un_projet_Web_e_commerce_Piece (1).pdfGestion_d_un_projet_Web_e_commerce_Piece (1).pdf
Gestion_d_un_projet_Web_e_commerce_Piece (1).pdf
 
Gestion_d_un_projet_Web_e_commerce_Piece.pdf
Gestion_d_un_projet_Web_e_commerce_Piece.pdfGestion_d_un_projet_Web_e_commerce_Piece.pdf
Gestion_d_un_projet_Web_e_commerce_Piece.pdf
 
OSIS 2017 - Scala REX dans Rudder
OSIS 2017 - Scala REX dans Rudder OSIS 2017 - Scala REX dans Rudder
OSIS 2017 - Scala REX dans Rudder
 
Dev Drink II (Flex by Navx)
Dev Drink II (Flex by Navx)Dev Drink II (Flex by Navx)
Dev Drink II (Flex by Navx)
 
TypeScript for dummies
TypeScript for dummiesTypeScript for dummies
TypeScript for dummies
 
DevFestBdm2019
DevFestBdm2019DevFestBdm2019
DevFestBdm2019
 
3 Microsoft Advanced Threat Analytics - Genève
3   Microsoft Advanced Threat Analytics - Genève3   Microsoft Advanced Threat Analytics - Genève
3 Microsoft Advanced Threat Analytics - Genève
 
Présentation de WAMP.ws, le protocole pour faire du PUB/SUB et RPC over Webso...
Présentation de WAMP.ws, le protocole pour faire du PUB/SUB et RPC over Webso...Présentation de WAMP.ws, le protocole pour faire du PUB/SUB et RPC over Webso...
Présentation de WAMP.ws, le protocole pour faire du PUB/SUB et RPC over Webso...
 

Plus de Modern Data Stack France

Plus de Modern Data Stack France (20)

Stash - Data FinOPS
Stash - Data FinOPSStash - Data FinOPS
Stash - Data FinOPS
 
Vue d'ensemble Dremio
Vue d'ensemble DremioVue d'ensemble Dremio
Vue d'ensemble Dremio
 
From Data Warehouse to Lakehouse
From Data Warehouse to LakehouseFrom Data Warehouse to Lakehouse
From Data Warehouse to Lakehouse
 
Talend spark meetup 03042017 - Paris Spark Meetup
Talend spark meetup 03042017 - Paris Spark MeetupTalend spark meetup 03042017 - Paris Spark Meetup
Talend spark meetup 03042017 - Paris Spark Meetup
 
Paris Spark Meetup - Trifacta - 03_04_2017
Paris Spark Meetup - Trifacta - 03_04_2017Paris Spark Meetup - Trifacta - 03_04_2017
Paris Spark Meetup - Trifacta - 03_04_2017
 
HUG France Feb 2016 - Migration de données structurées entre Hadoop et RDBMS ...
HUG France Feb 2016 - Migration de données structurées entre Hadoop et RDBMS ...HUG France Feb 2016 - Migration de données structurées entre Hadoop et RDBMS ...
HUG France Feb 2016 - Migration de données structurées entre Hadoop et RDBMS ...
 
Hadoop France meetup Feb2016 : recommendations with spark
Hadoop France meetup  Feb2016 : recommendations with sparkHadoop France meetup  Feb2016 : recommendations with spark
Hadoop France meetup Feb2016 : recommendations with spark
 
Hug janvier 2016 -EDF
Hug   janvier 2016 -EDFHug   janvier 2016 -EDF
Hug janvier 2016 -EDF
 
HUG France - 20160114 industrialisation_process_big_data CanalPlus
HUG France -  20160114 industrialisation_process_big_data CanalPlusHUG France -  20160114 industrialisation_process_big_data CanalPlus
HUG France - 20160114 industrialisation_process_big_data CanalPlus
 
Hugfr SPARK & RIAK -20160114_hug_france
Hugfr  SPARK & RIAK -20160114_hug_franceHugfr  SPARK & RIAK -20160114_hug_france
Hugfr SPARK & RIAK -20160114_hug_france
 
HUG France : HBase in Financial Industry par Pierre Bittner (Scaled Risk CTO)
HUG France : HBase in Financial Industry par Pierre Bittner (Scaled Risk CTO)HUG France : HBase in Financial Industry par Pierre Bittner (Scaled Risk CTO)
HUG France : HBase in Financial Industry par Pierre Bittner (Scaled Risk CTO)
 
Datalab 101 (Hadoop, Spark, ElasticSearch) par Jonathan Winandy - Paris Spark...
Datalab 101 (Hadoop, Spark, ElasticSearch) par Jonathan Winandy - Paris Spark...Datalab 101 (Hadoop, Spark, ElasticSearch) par Jonathan Winandy - Paris Spark...
Datalab 101 (Hadoop, Spark, ElasticSearch) par Jonathan Winandy - Paris Spark...
 
Record linkage, a real use case with spark ml - Paris Spark meetup Dec 2015
Record linkage, a real use case with spark ml  - Paris Spark meetup Dec 2015Record linkage, a real use case with spark ml  - Paris Spark meetup Dec 2015
Record linkage, a real use case with spark ml - Paris Spark meetup Dec 2015
 
Spark dataframe
Spark dataframeSpark dataframe
Spark dataframe
 
June Spark meetup : search as recommandation
June Spark meetup : search as recommandationJune Spark meetup : search as recommandation
June Spark meetup : search as recommandation
 
Spark ML par Xebia (Spark Meetup du 11/06/2015)
Spark ML par Xebia (Spark Meetup du 11/06/2015)Spark ML par Xebia (Spark Meetup du 11/06/2015)
Spark ML par Xebia (Spark Meetup du 11/06/2015)
 
Spark meetup at viadeo
Spark meetup at viadeoSpark meetup at viadeo
Spark meetup at viadeo
 
Paris Spark meetup : Extension de Spark (Tachyon / Spark JobServer) par jlamiel
Paris Spark meetup : Extension de Spark (Tachyon / Spark JobServer) par jlamielParis Spark meetup : Extension de Spark (Tachyon / Spark JobServer) par jlamiel
Paris Spark meetup : Extension de Spark (Tachyon / Spark JobServer) par jlamiel
 
Hadoop User Group 29Jan2015 Apache Flink / Haven / CapGemnini REX
Hadoop User Group 29Jan2015 Apache Flink / Haven / CapGemnini REXHadoop User Group 29Jan2015 Apache Flink / Haven / CapGemnini REX
Hadoop User Group 29Jan2015 Apache Flink / Haven / CapGemnini REX
 
The Cascading (big) data application framework
The Cascading (big) data application frameworkThe Cascading (big) data application framework
The Cascading (big) data application framework
 

Apache Flink par Bilal Baltagi Paris Spark Meetup Dec 2015

  • 1. Apache Flink Vue d’ensemble du framework Paris Spark Meetup 07/12/2015 Bilal BALTAGI @Bilal_baltagi
  • 2. Plan ● Introduction à Apache Flink ● L'écosystème Apache Flink ● Que fournit Apache Flink ○ Batch ○ Streaming ○ FlinkML et Gelly ● Apache Flink overview 2
  • 3. Introduction à Apache Flink ● Open-source Big Data Analytics Framework ● Conçu dès le départ pour : ○ In-memory process ○ Traitement en streaming ○ Nativement itérative ○ Mémoire autogérée ○ Optimisation basée sur le coût 3
  • 4. Introduction à Apache Flink ● Origine : ○ Stratosphere : Projet universitaire ○ Né à Berlin en 2008 ● Quelques dates : ○ Avril 2014 : Apache Projet Incubation ○ Décembre 2014 : Apache Projet Top level ○ Novembre 2015 : Dernière release 0.10.1 4
  • 5. Écosystème classique d’un Big data analytics framework 5
  • 6. 6
  • 7. Que fournis Apache Flink ● Moteur d'exécution : Distribué et évolutif ● Plusieurs API : ○ DataSet - Batch (Java, Scala et Python) ○ DataStream - temps réel (Java et Scala) ○ Table - Batch et temps réel (≈Relational SQL) 7
  • 8. Que fournis Apache Flink ● Domain-specific library (DSL) : ○ FlinkML : Machine Learning ○ Gelly : Traitement des graphes 8
  • 9. Actuellement le seul framework Open- source hybride : Batch and True Real Time 9
  • 10. Apache Flink : Traitement Batch ● Cost-based optimisation du plan d'exécution ○ En fonction du contexte (Single machine, cluster…) ○ En fonction de la volumétrie des données sources 10
  • 11. Apache Flink : Traitement Batch - plan d’execution 11
  • 12. Apache Flink : Traitement Batch - plan d’execution 12
  • 13. Apache Flink : Traitement Batch ● Flink gère sa propre mémoire : ○ Pas de Out-of-memory ○ Réduction du Garbage collector ○ Stabilité 13
  • 14. Apache Flink : Traitement Batch case class Word (word: String, frequency: Int) val lines: DataSet[String] = env.fromElements( "O Romeo, Romeo! wherefore art thou Romeo?”, …) lines.flatMap {line => line.split(" ") .map(word => Word(word,1))} .groupBy("word") .sum("frequency") .print() 14
  • 15. Apache Flink : Traitement Batch - comparaison TeraSort de 3,2To - 80Go/node Source : http://goo.gl/IqR97G 15
  • 16. Apache Flink : Traitement Batch - comparaison HashJoin - 10 Noeud - 256Mo + 240Go Source : http://goo.gl/IqR97G 16
  • 17. 4X Plus rapide que Spark 17
  • 18. Apache Flink : Traitement temps réel ● N’est plus en bêta depuis le 23/11/2015 ● Low-latency : temps réel ● High throughput : Volumétrie élevée ● Fault-tolerance Exactly-once : Pas de traitement dupliqué 18
  • 19. Apache Flink : Traitement temps réel ● Traitement native des itérations ● API riche : ○ Connecteurs (Flume, kafka, Twitter…) ○ Opérations identiques au batch 19
  • 20. Apache Flink : Traitement temps réel ● Quelques cas ou le “vrai temps réel” est critique : ○ Détection des fraudes et anomalies ○ Gestion des trafics ○ Recommandation en ligne Source : http://spark.apache.org/faq.html 20
  • 21. Apache Flink : Traitement temps réel Storm Vs. Flink Source : http://goo.gl/1Tgbn3 21
  • 22. 260X Plus de données que Storm 22
  • 23. Apache Flink : Traitement temps réel ● Exemple de traitement d’un flux continu avec Apache Flink : http://flink. apache.org/news/2015/12/04/Introducing-windows.html Capteur : Nombre de véhicules 23
  • 24. Apache Flink : Traitement temps réel Rolling sum : Retourne en continue la somme du nombre de véhicules passés 24
  • 25. Apache Flink : Traitement temps réel Tumbling windows: Retourne toutes les 60 secondes le nombre de véhicules qui viennent de passer 25
  • 26. Apache Flink : Traitement temps réel Windows sliding : Retourne toutes les 30 secondes le nombre de véhicules qui sont passés au cours des 60 dernières secondes 26
  • 27. Apache Flink : Traitement temps réel case class Word (word: String, frequency: Int) val lines: DataStream[String] = env.fromSocketStream(...) lines.flatMap {line => line.split(" ") .map(word => Word(word,1))} .window(Time.of(5,SECONDS)).every(Time.of(1,SECONDS)) .groupBy("word").sum("frequency") .print() 27
  • 28. Apache Flink : FlinkML ● FlinkML : Machine learning ● Inspiré de ○ Sikit-learn : Spécification propre des pipelines ML ○ Spark’s MLLIB : Alogrithmes scalables 28
  • 29. Apache Flink : Gelly ● Gelly : Traitement des graphes 29
  • 30. Apache Flink : FlinkML et Gelly ● Points forts : ○ In-memory data streaming ○ Code identique entre machine locale (extrait des données) et cluster (toutes les données) ○ Traitement nativement itérative ■ Iteration ■ Delta-iteration 30
  • 31. Apache Flink : FlinkML et Gelly ● Algorithmes avec itérations : ○ K-means ○ PageRank 31
  • 32. Apache Flink : Overview Real-time Stream Cyclic Batch Machine Learning Graph 32
  • 33. Apache Flink : overview - qui utilise Flink ? 33
  • 34. Flink 1.0 - Projet en cours... ● FlinkML streaming ● Sortir Table SQL de la bêta ● D’autres connecteurs 34
  • 35. Flink : Pour aller plus loin Site officiel : https://flink.apache.org/ Training : http://dataartisans.github.io/flink-training/ Gartner : http://goo.gl/mlgMoI KDnuggets : http://goo.gl/Z9hRvn Apache Flink vue par un développeur Spark : http://goo. gl/pygDyV 35
  • 36. Gardons contact ● https://www.linkedin.com/in/BilalBaltagi ● bilal.baltagi@gmail.com ● @bilal_baltagi http://www.meetup.com/fr/Paris-Apache-Flink-Meetup/ 36