SlideShare a Scribd company logo
Integrating Applications:
the Reactive Way
Nicola Ferraro
@ni_ferraro
Nicola Ferraro - JBCNConf Barcelona 2017
About Me
Follow me on twitter:
@ni_ferraro
Nicola Ferraro
Software Engineer at Red Hat
Working on Apache Camel, Fabric8,
JBoss Fuse, Fuse Integration
Services for Openshift
Nicola Ferraro - JBCNConf Barcelona 2017
Agenda
● What does it mean to be reactive?
○ Reactive Programming
○ Reactive Systems
● Application Integration
○ Enterprise Integration Patterns
○ Apache Camel
● Demo
● Integration in Reactive Systems
○ Patterns
○ Future Challenges
Nicola Ferraro - JBCNConf Barcelona 2017
What is Reactive Programming?
The goal of your
application is to:
“put a marble into
the bucket”
Phineas and Ferb
“Chain Reaction”
Disney
Nicola Ferraro - JBCNConf Barcelona 2017
What is Reactive Programming?
You design all the
steps (map, flatMap,
filter, kicks and
punches) that lead to
putting a marble in
the bucket.
A fixed schema that is
activated only when a
marble is kicked in
(reactive).
A gameplay on Youtube
Phineas and Ferb “Chain Reaction”
Disney
Nicola Ferraro - JBCNConf Barcelona 2017
reactive Programming Explained
merge(...)
stream1.map(e -> e.color(“#FF0”))
.zip(stream2, Bubble::of)
.merge(stream3)
.filter(Event::isAlmostRound)
.subscribe(bucket::put)
map(...)
filter(...)
zip(...)
?
Nicola Ferraro - JBCNConf Barcelona 2017
Streams vs. Request/Response
Is reactive programming only about streams?
No, but even request/response patterns are internally mapped
as sequence of events (at event loop level).
And there’s flatMap.
// for each event, call a function
// and take the results in the stream
stream.flatMap(e -> compute(e))
Nicola Ferraro - JBCNConf Barcelona 2017
How a “standard” application looks like?
Multiple “moving pieces”
(threads):
● Concurrency
● Resource contention
● Lock/Wait/Notify
● “One thread per request”
model
● “Thread migration” time
It is fun to play, but
inefficient!
Super Mario Bros 3
Nintendo
Nicola Ferraro - JBCNConf Barcelona 2017
What’s wrong with “1 thread per request”?
At some point in the past (~2011), Node.js (it was single
threaded) was faster than many (multithreaded) Java web
servers! (according to some benchmarks… also on multi-core
machines!)
How the hell was this possible?!?!?
#reqs handled per second
Higher is better!
Nicola Ferraro - JBCNConf Barcelona 2017
The reactor pattern (event loop)
A “Reactor”
The Simpsons
Event
Take
Execute
Handler
Reactor
And the multi-reactor
Multiple event loops, one two per physical core
(Vert.x)
leverage
asynchronous
I/O
1 thread event
per request
With no
concurrency
issues!
Nicola Ferraro - JBCNConf Barcelona 2017
The Golden Rule
Don’t block the event loop!
● Thread.sleep(...)
● synchronized(...)
● statement.executeQuery()
● myLongWorkflow.execute()
● outputStream.write(...)
Blocking operations can be executed
in a external thread pool.
Do not sleep!
Do not block the reactor!
Is asynchronous IO always possible at OS level? https://lwn.net/Articles/724198/
Nicola Ferraro - JBCNConf Barcelona 2017
What’s wrong with “1 thread per request”?
Performance comparison of
Tomcat (1 thread per request)
vs RxNetty (2015)
Reasons:
● Thread migration + context
switch
● Slower Garbage Collection
Details:
https://github.com/Netflix-Skunkworks/WSPerfLab
/blob/master/test-results/RxNetty_vs_Tomcat_Apr
il2015.pdf
Nicola Ferraro - JBCNConf Barcelona 2017
Limits of “1 thread per request” model
How many concurrent requests you can handle?
1 thread requires 1 MiB of stack memory by default
10k connections ~= 10 GiB of stack memory (just for the
threads)
What about the C10m problem?
http://c10m.robertgraham.com/p/manifesto.html
The
C10k
problem
Nicola Ferraro - JBCNConf Barcelona 2017
Reactive Programming vs. Reactive Systems
“Reactive: Readily responsive to a stimulus”, Merriam Webster
● Responsive (react to user requests):
○ Having rapid response times
● Resilient (react to failures)
○ Being responsive also in case of failures (e.g. replication, retry)
● Elastic (react to load)
○ No bottlenecks, can scale according to load
● Message driven (react to events/messages)
○ Communication based on asynchronous message passing, with location
transparency and backpressure
The reactive manifesto: http://www.reactivemanifesto.org/
Nicola Ferraro - JBCNConf Barcelona 2017
Reactive “packages”
PROJECT REACTOR
(v. 5)
Toolkits for building Reactive Systems Reactive Programming Frameworks
Help me to classify them ...
streams
?
Nicola Ferraro - JBCNConf Barcelona 2017
Agenda
● What does it mean to be reactive?
○ Reactive Programming
○ Reactive Systems
● Application Integration
○ Enterprise Integration Patterns
○ Apache Camel
● Demo
● Integration in Reactive Systems
○ Patterns
○ Future Challenges
Nicola Ferraro - JBCNConf Barcelona 2017
Integration
Nobody lives in isolation.
Integration is about:
● Communication (Messaging)
● Converting protocols
● Mapping Bounded Contexts
● Message Correlation
● Routing
● Flow Control
● ...
Nicola Ferraro - JBCNConf Barcelona 2017
The integration platform
Apache Camel is a powerful
integration framework based on
enterprise integration patterns!
More than 200 components
Can connect to any platform The new logo (proposal)
by Zoran Regvart
Nicola Ferraro - JBCNConf Barcelona 2017
Camel: the Components
ahc, ahc-ws, amqp, apns, asterisk, atmos, atmosphere-websocket, atom, avro, aws, azure, bam, barcode, base64,
beanio, beanstalk, bean-validator, bindy, blueprint, bonita, boon, box, braintree, cache, cassandraql, castor,
cdi, chronicle, chunk, cmis, cm-sms, coap, cometd, consul, context, core-osgi, core-xml, couchbase, couchdb,
crypto, csv, cxf, cxf-transport, digitalocean, disruptor, dns, docker, dozer, drill, dropbox, eclipse, ehcache,
ejb, elasticsearch, elasticsearch5, elsql, etcd, eventadmin, exec, facebook, fastjson, firebase, flatpack, flink,
fop, freemarker, ftp, ganglia, geocoder, git, github, google-calendar, google-drive, google-mail, google-pubsub,
gora, grape, groovy, groovy-dsl, grpc, gson, guava-eventbus, guice, hawtdb, hazelcast, hbase, hdfs, hdfs2,
headersmap, hessian, hipchat, hl7, http, http4, http-common, hystrix, ibatis, ical, ignite, infinispan, influxdb,
irc, ironmq, jackson, jacksonxml, jasypt, javaspace, jaxb, jbpm, jcache, jclouds, jcr, jdbc, jetty, jetty9,
jetty-common, jgroups, jibx, jing, jira, jms, jmx, johnzon, jolt, josql, jpa, jsch, jsonpath, jt400, juel,
jxpath, kafka, kestrel, krati, kubernetes, kura, ldap, leveldb, linkedin, lucene, lumberjack, lzf, mail, metrics,
milo, mina, mina2, mllp, mongodb, mongodb3, mongodb-gridfs, mqtt, msv, mustache, mvel, mybatis, nagios, nats,
netty, netty4, netty4-http, netty-http, ognl, olingo2, olingo4, openshift, openstack, opentracing, optaplanner,
paho, paxlogging, pdf, pgevent, printer, protobuf, pubnub, quartz, quartz2, quickfix, rabbitmq, reactive-streams,
reactor, restlet, rest-swagger, ribbon, rmi, routebox, rss, ruby, rx, rxjava2, salesforce, sap-netweaver, saxon,
scala, schematron, scr, script, servicenow, servlet, servletlistener, shiro, sip, sjms, sjms2, slack, smpp,
snakeyaml, snmp, soap, solr, spark, spark-rest, splunk, spring, spring-batch, spring-boot, spring-cloud,
spring-cloud-netflix, spring-dm, spring-integration, spring-javaconfig, spring-ldap, spring-redis,
spring-security, spring-web, spring-ws, sql, ssh, stax, stomp, stream, stringtemplate, swagger, swagger-java,
syslog, tagsoup, tarfile, telegram, test, test-blueprint, test-cdi, test-karaf, testng, test-spring, thrift,
tika, twilio, twitter, undertow, univocity-parsers, urlrewrite, velocity, vertx, weather, websocket, xmlbeans,
xmljson, xmlrpc, xmlsecurity, xmpp, xstream, yammer, zendesk, zipfile, zipkin, zookeeper, zookeeper-master …
Nicola Ferraro - JBCNConf Barcelona 2017
Basic Usage
// Simple routing
from(“jms:queue/orders”)
.log(“Processing order: ${body}”)
.to(“http://myservice”)
.to(“smtp:localhost:25”);
Isn’t “.to()” close to “.map()”?
// A (not so) much complicated
// example
from(“hdfs:/home/nicola/data”)
.unmarshal().json() // json array
.split().body()
.choice()
.when(...)
.to(“jdbc:...”)
.otherwise()
.log(“Skipped ${body}”)
Nicola Ferraro - JBCNConf Barcelona 2017
Camel: some EIPs
Fix out of order
messages
Aggregating results in
groups
from(“...”).resequence(header(“timestamp”))...
from(“...”).aggregate(header(“orderId”))...
Nicola Ferraro - JBCNConf Barcelona 2017
Camel: some EIPs
Recipient list
Content Based Routing
from(“...”).recipientList(header(“recipient”))...
from(“...”).choice().when()...otherwise()
Nicola Ferraro - JBCNConf Barcelona 2017
Camel: some EIPs
Hystrix
Others (important!):
● Redelivery Policy: setup number of redelivery attempts and delays
● Throttler: adjust message speed for slow consumers
● Service Call: integrate with an external service registry (consul, ribbon, kubernetes)
● Load Balancer: balance load to multiple endpoints using custom strategies
from(“...”)
.hystrix()
.to(“http://service”)
.onFallback()
.transform()...
Open and close the circuit to an external service
and provide fallback responses to the client.
S1 S2
Nicola Ferraro - JBCNConf Barcelona 2017
Is Camel Reactive?
Camel 3.0 will have a fully reactive core.
Camel 2.20 is not fully reactive, but:
● Uses asynchronous processing by default (no 1 thread pr)
● Supports backpressure and throttling
● Has multiple components for asynchronous I/O
No event loops and reactors, but it’s fast (especially the
latest version)!
Nicola Ferraro - JBCNConf Barcelona 2017
The goal: create a bigger reactive system
Integration in Reactive Systems
Browser
(Vert.x)
Microservice 1
(Vert.x)
EventBus Microservice 2
(Vert.x)
Resiliency, location
transparency
MS 1 MS 2
MS 3 MS 4
Another Reactive/Non-reactive Ecosystem
Integration
Microservice Integration
Microservice
Optional
Nicola Ferraro - JBCNConf Barcelona 2017
Communication in Reactive Applications
Inside the JVM:
Reactive Streams
http://www.reactive-streams.org/
A specification for asynchronous stream processing with
non-blocking backpressure [?].
PROJECT REACTOR
JVM
Reactive Streams
Nicola Ferraro - JBCNConf Barcelona 2017
Reactive Streams Visualized
public interface Publisher<T> {
public void subscribe(Subscriber<? super T> s);
}
public interface Subscriber<T> {
public void onSubscribe(Subscription s);
public void onNext(T t);
public void onError(Throwable t);
public void onComplete();
}
public interface Subscription {
public void request(long n);
public void cancel();
}
public interface Processor<T, R> extends Subscriber<T>,
Publisher<R> {
}
Just this 4 interfaces (and the rules to use them).
Java 9 Flow API: Flow.Publisher, Flow.Subscriber, Flow.Subscription, Flow.Processor
Nicola Ferraro - JBCNConf Barcelona 2017
Agenda
● What does it mean to be reactive?
○ Reactive Programming
○ Reactive Systems
● Application Integration
○ Enterprise Integration Patterns
○ Apache Camel
● Demo
● Integration in Reactive Systems
○ Patterns
○ Future Challenges
Nicola Ferraro - JBCNConf Barcelona 2017
Demo
Use camel-reactive-streams to exchange data with a reactive
library (Vert.x → rx-java2 → Camel).
Use camel-netty-http to connect a Spring-Boot 2 (Spring 5)
WebFlux service.
Use camel-grpc to forward a stream to a remote service and
get the response stream back.
● https://github.com/nicolaferraro/reactive-demo (note: requires camel 2.20-snapshot)
PROJECT REACTOR
Nicola Ferraro - JBCNConf Barcelona 2017
Demo: considerations
I’ve used the generic camel-reactive-streams component but
there’s also a specific connector for Vert.x (connects
directly to the Eventbus):
// Using the camel-vertx component
from(“vertx:raw-points”)
.to(“...”)
.to(“vertx:enhanced-points”);
Nicola Ferraro - JBCNConf Barcelona 2017
Agenda
● What does it mean to be reactive?
○ Reactive Programming
○ Reactive Systems
● Application Integration
○ Enterprise Integration Patterns
○ Apache Camel
● Demo
● Integration in Reactive Systems
○ Patterns
○ Future Challenges
Nicola Ferraro - JBCNConf Barcelona 2017
Backpressure?
OP Normal Scenario
Normal operator or
boundary betweeen
reactive streams
OP
Too much water
(events)
SLOW
buffer full
pressure in the pipes (like with water!)
Backpressure
“Remember, you can’t put too much water in a nuclear reactor”, Saturday Night Live, 1984
buffer full
Backpressure
Nicola Ferraro - JBCNConf Barcelona 2017
Backpressure in Reactive Streams
onSubscribe(sub)
subscribe()
request(1)
onNext(“m1”)
request(2)
onNext(“m2”)
onNext(“m3”)
Publisher
Subscriber
Nicola Ferraro - JBCNConf Barcelona 2017
Limited Resources: microservices - no backpressure
Microservice 1
Microservice 2
Microservice 3
Microservice 4
Can’t process all events:
● Timeout
● HTTP 503
In req/resp mode,
you can do circuit
breaking.
In in-only
(streaming) mode,
you will retry
(increase load)
Nicola Ferraro - JBCNConf Barcelona 2017
Limited Resources: microservices with backpressure
Microservice 1
Microservice 2
Microservice 4
Microservice 3You can buffer at the
source!
Flow control at
system level
backpressure
Less responsive, but you
can handle peaks
Later, you can scale out
“Microservice 4” to make
the system more
responsive
Nicola Ferraro - JBCNConf Barcelona 2017
End-to-End Backpressure: In-Only Stream
Java / JS /
Python
Service 1
Java / JS /
Python
Service 2
backpressured
How???
RSocket
http://rsocket.io/
Application protocol providing reactive streams semantics.
Other solutions?? Designed for efficiency at low level
onNext
onError
onComplete
Nicola Ferraro - JBCNConf Barcelona 2017
End-to-End Backpressure: In-Only Stream
This backpressure stuff is not new…
Nicola Ferraro - JBCNConf Barcelona 2017
Back to TCP
TPC implements a sliding window protocol for flow control!
Java / JS /
Python
Java / JS /
Python
TCP / IP
data
ack + window size
You cannot send more data
than requested to a TCP
recipient!
TCP is backpressure aware!
Nicola Ferraro - JBCNConf Barcelona 2017
Backpressure at Application Level: In-Only Stream
App 1
TCP
Local Backpressure:
do not write too much
App 2
TCP
Local Backpressure:
do not read if can’t process
backpressured
Application Level
Backpressure
Sliding window flow control
Can work also with higher level protocols
● HTTP
● Websocket
● SSE
● gRPC End-to-end backpressure
Nicola Ferraro - JBCNConf Barcelona 2017
Backpressure: Stream → Camel
What in case of request/response messaging?
Reactive
Streams
Rx-Java Camel
from(“reactive-streams:events”)
.throttle(3).timePeriodMillis(10000)
.to(“http://dinosaurs.io/api/echo”);
Camel
Producer
External Servicebackpressure
from(“reactive-streams:events?maxInflightExchanges=20”)
.to(“http://dinosaurs.io/api/echo”);
No more than 20 concurrent reqsNo more than 3 reqs in 10 secs
In-Out
Nicola Ferraro - JBCNConf Barcelona 2017
Backpressure: Camel → Stream
Camel
Consumer
Reactive
Streams
What happens when backpressure slows down Camel?
Reactor-CoreCamel
from(“jms:events”)
.routePolicy(maxExchangesPolicy)
.to(“reactive-streams:events”);
Message Source
backpressure
Camel will pause the consumer
in case of backpressure
Flux<Message>
Nicola Ferraro - JBCNConf Barcelona 2017
Adding Elasticity: Load Balancer
canvas1
canvas2Camel Load Balancer:
from(“...”)
.loadBalance().sticky(canvasIdExpr())
.to(“endpoint1”, “endpoint2”)
Supports:
● Round robin, random, custom
● Failover
● Mixing with ServiceCall EIP (location transparency + load balancing) Works with any protocol:
HTTP, TCP, GRPC, ...
Streams or
RPC
Nicola Ferraro - JBCNConf Barcelona 2017
Adding (a bit of) Location Transparency
192.168.0.22
service-1 service-2
Service Registry
● Consul
● Etcd
● Kubernetes
● Ribbon
Camel ServiceCall EIP:
from(“...”)
.serviceCall(“service-2”)
.to(“...”)
Nicola Ferraro - JBCNConf Barcelona 2017
Adding Location Transparency and Resiliency
Reactive
Streams
Rx-Java Camel
Camel
Producer
Camel
Consumer
Messaging Broker
(your choice)
● JMS
● Kafka (anti-backpressure)
● AMQP
● MQTT
backpressure
Allows all kind of messaging patterns:
● P2P In-Only
● P2P In-Out
● Pub/Sub
Send messages to:
● Queues
● Topics
backpressure
If you have a fast-enough
messaging broker, you don’t have to
care a lot about backpressure when
writing (anti-backpressure)
Nicola Ferraro - JBCNConf Barcelona 2017
@ni_ferraro
That’s all folks!

More Related Content

What's hot

Troubleshooting Kerberos in Hadoop: Taming the Beast
Troubleshooting Kerberos in Hadoop: Taming the BeastTroubleshooting Kerberos in Hadoop: Taming the Beast
Troubleshooting Kerberos in Hadoop: Taming the Beast
DataWorks Summit
 
Apache Spark PDF
Apache Spark PDFApache Spark PDF
Apache Spark PDF
Naresh Rupareliya
 
Introduction to Apache Flink - Fast and reliable big data processing
Introduction to Apache Flink - Fast and reliable big data processingIntroduction to Apache Flink - Fast and reliable big data processing
Introduction to Apache Flink - Fast and reliable big data processing
Till Rohrmann
 
Introduction to Kafka Cruise Control
Introduction to Kafka Cruise ControlIntroduction to Kafka Cruise Control
Introduction to Kafka Cruise Control
Jiangjie Qin
 
Kubernetes design principles, patterns and ecosystem
Kubernetes design principles, patterns and ecosystemKubernetes design principles, patterns and ecosystem
Kubernetes design principles, patterns and ecosystem
Sreenivas Makam
 
Rate limits and Performance
Rate limits and PerformanceRate limits and Performance
Rate limits and Performance
supergigas
 
Decoupling your application using Symfony Messenger and events
Decoupling your application using Symfony Messenger and eventsDecoupling your application using Symfony Messenger and events
Decoupling your application using Symfony Messenger and events
hmmonteiro
 
Apache kafka performance(latency)_benchmark_v0.3
Apache kafka performance(latency)_benchmark_v0.3Apache kafka performance(latency)_benchmark_v0.3
Apache kafka performance(latency)_benchmark_v0.3
SANG WON PARK
 
Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...
Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...
Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...
Databricks
 
Introduction to Actor Model and Akka
Introduction to Actor Model and AkkaIntroduction to Actor Model and Akka
Introduction to Actor Model and Akka
Yung-Lin Ho
 
A Deep Dive into Kafka Controller
A Deep Dive into Kafka ControllerA Deep Dive into Kafka Controller
A Deep Dive into Kafka Controller
confluent
 
Streaming SQL with Apache Calcite
Streaming SQL with Apache CalciteStreaming SQL with Apache Calcite
Streaming SQL with Apache Calcite
Julian Hyde
 
How I learned to time travel, or, data pipelining and scheduling with Airflow
How I learned to time travel, or, data pipelining and scheduling with AirflowHow I learned to time travel, or, data pipelining and scheduling with Airflow
How I learned to time travel, or, data pipelining and scheduling with Airflow
PyData
 
Akka Actor presentation
Akka Actor presentationAkka Actor presentation
Akka Actor presentation
Gene Chang
 
Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...
Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...
Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...
Lucidworks
 
RabbitMQ & Kafka
RabbitMQ & KafkaRabbitMQ & Kafka
RabbitMQ & Kafka
VMware Tanzu
 
Keeping Spark on Track: Productionizing Spark for ETL
Keeping Spark on Track: Productionizing Spark for ETLKeeping Spark on Track: Productionizing Spark for ETL
Keeping Spark on Track: Productionizing Spark for ETL
Databricks
 
Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)
Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)
Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)
Lucas Jellema
 
Improved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and AlertmanagerImproved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and Alertmanager
Julien Pivotto
 
React Server Side Rendering with Next.js
React Server Side Rendering with Next.jsReact Server Side Rendering with Next.js
React Server Side Rendering with Next.js
Jamie Barton 👨🏻‍💻
 

What's hot (20)

Troubleshooting Kerberos in Hadoop: Taming the Beast
Troubleshooting Kerberos in Hadoop: Taming the BeastTroubleshooting Kerberos in Hadoop: Taming the Beast
Troubleshooting Kerberos in Hadoop: Taming the Beast
 
Apache Spark PDF
Apache Spark PDFApache Spark PDF
Apache Spark PDF
 
Introduction to Apache Flink - Fast and reliable big data processing
Introduction to Apache Flink - Fast and reliable big data processingIntroduction to Apache Flink - Fast and reliable big data processing
Introduction to Apache Flink - Fast and reliable big data processing
 
Introduction to Kafka Cruise Control
Introduction to Kafka Cruise ControlIntroduction to Kafka Cruise Control
Introduction to Kafka Cruise Control
 
Kubernetes design principles, patterns and ecosystem
Kubernetes design principles, patterns and ecosystemKubernetes design principles, patterns and ecosystem
Kubernetes design principles, patterns and ecosystem
 
Rate limits and Performance
Rate limits and PerformanceRate limits and Performance
Rate limits and Performance
 
Decoupling your application using Symfony Messenger and events
Decoupling your application using Symfony Messenger and eventsDecoupling your application using Symfony Messenger and events
Decoupling your application using Symfony Messenger and events
 
Apache kafka performance(latency)_benchmark_v0.3
Apache kafka performance(latency)_benchmark_v0.3Apache kafka performance(latency)_benchmark_v0.3
Apache kafka performance(latency)_benchmark_v0.3
 
Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...
Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...
Building a Versatile Analytics Pipeline on Top of Apache Spark with Mikhail C...
 
Introduction to Actor Model and Akka
Introduction to Actor Model and AkkaIntroduction to Actor Model and Akka
Introduction to Actor Model and Akka
 
A Deep Dive into Kafka Controller
A Deep Dive into Kafka ControllerA Deep Dive into Kafka Controller
A Deep Dive into Kafka Controller
 
Streaming SQL with Apache Calcite
Streaming SQL with Apache CalciteStreaming SQL with Apache Calcite
Streaming SQL with Apache Calcite
 
How I learned to time travel, or, data pipelining and scheduling with Airflow
How I learned to time travel, or, data pipelining and scheduling with AirflowHow I learned to time travel, or, data pipelining and scheduling with Airflow
How I learned to time travel, or, data pipelining and scheduling with Airflow
 
Akka Actor presentation
Akka Actor presentationAkka Actor presentation
Akka Actor presentation
 
Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...
Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...
Learning to Rank in Solr: Presented by Michael Nilsson & Diego Ceccarelli, Bl...
 
RabbitMQ & Kafka
RabbitMQ & KafkaRabbitMQ & Kafka
RabbitMQ & Kafka
 
Keeping Spark on Track: Productionizing Spark for ETL
Keeping Spark on Track: Productionizing Spark for ETLKeeping Spark on Track: Productionizing Spark for ETL
Keeping Spark on Track: Productionizing Spark for ETL
 
Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)
Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)
Microservices, Node, Dapr and more - Part One (Fontys Hogeschool, Spring 2022)
 
Improved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and AlertmanagerImproved alerting with Prometheus and Alertmanager
Improved alerting with Prometheus and Alertmanager
 
React Server Side Rendering with Next.js
React Server Side Rendering with Next.jsReact Server Side Rendering with Next.js
React Server Side Rendering with Next.js
 

Similar to Integrating Applications: the Reactive Way

Why scala is not my ideal language and what I can do with this
Why scala is not my ideal language and what I can do with thisWhy scala is not my ideal language and what I can do with this
Why scala is not my ideal language and what I can do with this
Ruslan Shevchenko
 
StrongLoop Overview
StrongLoop OverviewStrongLoop Overview
StrongLoop Overview
Shubhra Kar
 
Microservices Application Tracing Standards and Simulators - Adrians at OSCON
Microservices Application Tracing Standards and Simulators - Adrians at OSCONMicroservices Application Tracing Standards and Simulators - Adrians at OSCON
Microservices Application Tracing Standards and Simulators - Adrians at OSCON
Adrian Cockcroft
 
XML Amsterdam 2012 Keynote
XML Amsterdam 2012 KeynoteXML Amsterdam 2012 Keynote
XML Amsterdam 2012 Keynote
jimfuller2009
 
SOA in the cloud with FraSCAti, OW2con11, Nov 24-25, Paris
SOA in the cloud with FraSCAti, OW2con11, Nov 24-25, ParisSOA in the cloud with FraSCAti, OW2con11, Nov 24-25, Paris
SOA in the cloud with FraSCAti, OW2con11, Nov 24-25, ParisOW2
 
Introduction to Phoenix Framework (Elixir) 2016-01-07
Introduction to Phoenix Framework (Elixir) 2016-01-07Introduction to Phoenix Framework (Elixir) 2016-01-07
Introduction to Phoenix Framework (Elixir) 2016-01-07
Svein Fidjestøl
 
Onyx data processing the clojure way
Onyx   data processing  the clojure wayOnyx   data processing  the clojure way
Onyx data processing the clojure way
Bahadir Cambel
 
Apache Beam (incubating)
Apache Beam (incubating)Apache Beam (incubating)
Apache Beam (incubating)
Apache Apex
 
Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...
Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...
Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...
Claus Ibsen
 
End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013
Alexandre Morgaut
 
Wakanda 2013-07-02
Wakanda 2013-07-02Wakanda 2013-07-02
Wakanda 2013-07-02
kmiyako
 
Integrating vert.x v2
Integrating vert.x v2Integrating vert.x v2
Integrating vert.x v2
Francisco Alves
 
Cloud Foundry Meetup Stuttgart 2017 - Spring Cloud Development
Cloud Foundry Meetup Stuttgart 2017 - Spring Cloud DevelopmentCloud Foundry Meetup Stuttgart 2017 - Spring Cloud Development
Cloud Foundry Meetup Stuttgart 2017 - Spring Cloud Development
Andreas Falk
 
Docker Platform and Ecosystem Nov 2015
Docker Platform and Ecosystem Nov 2015Docker Platform and Ecosystem Nov 2015
Docker Platform and Ecosystem Nov 2015
Patrick Chanezon
 
SDVIs and In-Situ Visualization on TACC's Stampede
SDVIs and In-Situ Visualization on TACC's StampedeSDVIs and In-Situ Visualization on TACC's Stampede
SDVIs and In-Situ Visualization on TACC's Stampede
Intel® Software
 
OpenShift Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud
OpenShift  Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud OpenShift  Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud
OpenShift Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud
Hidetsugu Sugiyama
 
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
Alexandre Morgaut
 
Server side JavaScript: going all the way
Server side JavaScript: going all the wayServer side JavaScript: going all the way
Server side JavaScript: going all the way
Oleg Podsechin
 
Android RenderScript on LLVM
Android RenderScript on LLVMAndroid RenderScript on LLVM
Android RenderScript on LLVM
John Lee
 
Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013Rack Lin
 

Similar to Integrating Applications: the Reactive Way (20)

Why scala is not my ideal language and what I can do with this
Why scala is not my ideal language and what I can do with thisWhy scala is not my ideal language and what I can do with this
Why scala is not my ideal language and what I can do with this
 
StrongLoop Overview
StrongLoop OverviewStrongLoop Overview
StrongLoop Overview
 
Microservices Application Tracing Standards and Simulators - Adrians at OSCON
Microservices Application Tracing Standards and Simulators - Adrians at OSCONMicroservices Application Tracing Standards and Simulators - Adrians at OSCON
Microservices Application Tracing Standards and Simulators - Adrians at OSCON
 
XML Amsterdam 2012 Keynote
XML Amsterdam 2012 KeynoteXML Amsterdam 2012 Keynote
XML Amsterdam 2012 Keynote
 
SOA in the cloud with FraSCAti, OW2con11, Nov 24-25, Paris
SOA in the cloud with FraSCAti, OW2con11, Nov 24-25, ParisSOA in the cloud with FraSCAti, OW2con11, Nov 24-25, Paris
SOA in the cloud with FraSCAti, OW2con11, Nov 24-25, Paris
 
Introduction to Phoenix Framework (Elixir) 2016-01-07
Introduction to Phoenix Framework (Elixir) 2016-01-07Introduction to Phoenix Framework (Elixir) 2016-01-07
Introduction to Phoenix Framework (Elixir) 2016-01-07
 
Onyx data processing the clojure way
Onyx   data processing  the clojure wayOnyx   data processing  the clojure way
Onyx data processing the clojure way
 
Apache Beam (incubating)
Apache Beam (incubating)Apache Beam (incubating)
Apache Beam (incubating)
 
Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...
Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...
Red Hat Nordics 2020 - Apache Camel 3 the next generation of enterprise integ...
 
End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013End-to-end HTML5 APIs - The Geek Gathering 2013
End-to-end HTML5 APIs - The Geek Gathering 2013
 
Wakanda 2013-07-02
Wakanda 2013-07-02Wakanda 2013-07-02
Wakanda 2013-07-02
 
Integrating vert.x v2
Integrating vert.x v2Integrating vert.x v2
Integrating vert.x v2
 
Cloud Foundry Meetup Stuttgart 2017 - Spring Cloud Development
Cloud Foundry Meetup Stuttgart 2017 - Spring Cloud DevelopmentCloud Foundry Meetup Stuttgart 2017 - Spring Cloud Development
Cloud Foundry Meetup Stuttgart 2017 - Spring Cloud Development
 
Docker Platform and Ecosystem Nov 2015
Docker Platform and Ecosystem Nov 2015Docker Platform and Ecosystem Nov 2015
Docker Platform and Ecosystem Nov 2015
 
SDVIs and In-Situ Visualization on TACC's Stampede
SDVIs and In-Situ Visualization on TACC's StampedeSDVIs and In-Situ Visualization on TACC's Stampede
SDVIs and In-Situ Visualization on TACC's Stampede
 
OpenShift Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud
OpenShift  Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud OpenShift  Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud
OpenShift Kubernetes Native Infrastructure for 5GC and Telco Edge Cloud
 
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
State of the art: Server-Side JavaScript - WebWorkersCamp IV - Open World For...
 
Server side JavaScript: going all the way
Server side JavaScript: going all the wayServer side JavaScript: going all the way
Server side JavaScript: going all the way
 
Android RenderScript on LLVM
Android RenderScript on LLVMAndroid RenderScript on LLVM
Android RenderScript on LLVM
 
Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013Phalcon / Zephir Introduction at PHPConfTW2013
Phalcon / Zephir Introduction at PHPConfTW2013
 

More from Nicola Ferraro

Camel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel KCamel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel K
Nicola Ferraro
 
ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...
ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...
ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...
Nicola Ferraro
 
ApacheCon NA - Apache Camel K: a cloud-native integration platform
ApacheCon NA - Apache Camel K: a cloud-native integration platformApacheCon NA - Apache Camel K: a cloud-native integration platform
ApacheCon NA - Apache Camel K: a cloud-native integration platform
Nicola Ferraro
 
Analyzing Data at Scale with Apache Spark
Analyzing Data at Scale with Apache SparkAnalyzing Data at Scale with Apache Spark
Analyzing Data at Scale with Apache Spark
Nicola Ferraro
 
Cloud Native Applications on Kubernetes: a DevOps Approach
Cloud Native Applications on Kubernetes: a DevOps ApproachCloud Native Applications on Kubernetes: a DevOps Approach
Cloud Native Applications on Kubernetes: a DevOps Approach
Nicola Ferraro
 
Extending DevOps to Big Data Applications with Kubernetes
Extending DevOps to Big Data Applications with KubernetesExtending DevOps to Big Data Applications with Kubernetes
Extending DevOps to Big Data Applications with Kubernetes
Nicola Ferraro
 
A brief history of "big data"
A brief history of "big data"A brief history of "big data"
A brief history of "big data"
Nicola Ferraro
 

More from Nicola Ferraro (7)

Camel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel KCamel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel K
 
ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...
ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...
ApacheCon NA - Apache Camel K: connect your Knative serverless applications w...
 
ApacheCon NA - Apache Camel K: a cloud-native integration platform
ApacheCon NA - Apache Camel K: a cloud-native integration platformApacheCon NA - Apache Camel K: a cloud-native integration platform
ApacheCon NA - Apache Camel K: a cloud-native integration platform
 
Analyzing Data at Scale with Apache Spark
Analyzing Data at Scale with Apache SparkAnalyzing Data at Scale with Apache Spark
Analyzing Data at Scale with Apache Spark
 
Cloud Native Applications on Kubernetes: a DevOps Approach
Cloud Native Applications on Kubernetes: a DevOps ApproachCloud Native Applications on Kubernetes: a DevOps Approach
Cloud Native Applications on Kubernetes: a DevOps Approach
 
Extending DevOps to Big Data Applications with Kubernetes
Extending DevOps to Big Data Applications with KubernetesExtending DevOps to Big Data Applications with Kubernetes
Extending DevOps to Big Data Applications with Kubernetes
 
A brief history of "big data"
A brief history of "big data"A brief history of "big data"
A brief history of "big data"
 

Recently uploaded

top nidhi software solution freedownload
top nidhi software solution freedownloadtop nidhi software solution freedownload
top nidhi software solution freedownload
vrstrong314
 
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
Matt Welsh
 
Enhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdfEnhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdf
Globus
 
2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx
Georgi Kodinov
 
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...
informapgpstrackings
 
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdfEnhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Jay Das
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
Ortus Solutions, Corp
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Natan Silnitsky
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
e20449
 
Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"
Donna Lenk
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
wottaspaceseo
 
Cyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdfCyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdf
Cyanic lab
 
BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024
Ortus Solutions, Corp
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
Globus
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus
 
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Globus
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus
 
RISE with SAP and Journey to the Intelligent Enterprise
RISE with SAP and Journey to the Intelligent EnterpriseRISE with SAP and Journey to the Intelligent Enterprise
RISE with SAP and Journey to the Intelligent Enterprise
Srikant77
 
Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
Globus
 

Recently uploaded (20)

top nidhi software solution freedownload
top nidhi software solution freedownloadtop nidhi software solution freedownload
top nidhi software solution freedownload
 
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology Solutions
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
 
Enhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdfEnhancing Research Orchestration Capabilities at ORNL.pdf
Enhancing Research Orchestration Capabilities at ORNL.pdf
 
2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx
 
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...
Field Employee Tracking System| MiTrack App| Best Employee Tracking Solution|...
 
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdfEnhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
 
Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
 
Cyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdfCyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdf
 
BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
 
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...
 
Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024Globus Connect Server Deep Dive - GlobusWorld 2024
Globus Connect Server Deep Dive - GlobusWorld 2024
 
RISE with SAP and Journey to the Intelligent Enterprise
RISE with SAP and Journey to the Intelligent EnterpriseRISE with SAP and Journey to the Intelligent Enterprise
RISE with SAP and Journey to the Intelligent Enterprise
 
Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
 

Integrating Applications: the Reactive Way

  • 1. Integrating Applications: the Reactive Way Nicola Ferraro @ni_ferraro
  • 2. Nicola Ferraro - JBCNConf Barcelona 2017 About Me Follow me on twitter: @ni_ferraro Nicola Ferraro Software Engineer at Red Hat Working on Apache Camel, Fabric8, JBoss Fuse, Fuse Integration Services for Openshift
  • 3. Nicola Ferraro - JBCNConf Barcelona 2017 Agenda ● What does it mean to be reactive? ○ Reactive Programming ○ Reactive Systems ● Application Integration ○ Enterprise Integration Patterns ○ Apache Camel ● Demo ● Integration in Reactive Systems ○ Patterns ○ Future Challenges
  • 4. Nicola Ferraro - JBCNConf Barcelona 2017 What is Reactive Programming? The goal of your application is to: “put a marble into the bucket” Phineas and Ferb “Chain Reaction” Disney
  • 5. Nicola Ferraro - JBCNConf Barcelona 2017 What is Reactive Programming? You design all the steps (map, flatMap, filter, kicks and punches) that lead to putting a marble in the bucket. A fixed schema that is activated only when a marble is kicked in (reactive). A gameplay on Youtube Phineas and Ferb “Chain Reaction” Disney
  • 6. Nicola Ferraro - JBCNConf Barcelona 2017 reactive Programming Explained merge(...) stream1.map(e -> e.color(“#FF0”)) .zip(stream2, Bubble::of) .merge(stream3) .filter(Event::isAlmostRound) .subscribe(bucket::put) map(...) filter(...) zip(...) ?
  • 7. Nicola Ferraro - JBCNConf Barcelona 2017 Streams vs. Request/Response Is reactive programming only about streams? No, but even request/response patterns are internally mapped as sequence of events (at event loop level). And there’s flatMap. // for each event, call a function // and take the results in the stream stream.flatMap(e -> compute(e))
  • 8. Nicola Ferraro - JBCNConf Barcelona 2017 How a “standard” application looks like? Multiple “moving pieces” (threads): ● Concurrency ● Resource contention ● Lock/Wait/Notify ● “One thread per request” model ● “Thread migration” time It is fun to play, but inefficient! Super Mario Bros 3 Nintendo
  • 9. Nicola Ferraro - JBCNConf Barcelona 2017 What’s wrong with “1 thread per request”? At some point in the past (~2011), Node.js (it was single threaded) was faster than many (multithreaded) Java web servers! (according to some benchmarks… also on multi-core machines!) How the hell was this possible?!?!? #reqs handled per second Higher is better!
  • 10. Nicola Ferraro - JBCNConf Barcelona 2017 The reactor pattern (event loop) A “Reactor” The Simpsons Event Take Execute Handler Reactor And the multi-reactor Multiple event loops, one two per physical core (Vert.x) leverage asynchronous I/O 1 thread event per request With no concurrency issues!
  • 11. Nicola Ferraro - JBCNConf Barcelona 2017 The Golden Rule Don’t block the event loop! ● Thread.sleep(...) ● synchronized(...) ● statement.executeQuery() ● myLongWorkflow.execute() ● outputStream.write(...) Blocking operations can be executed in a external thread pool. Do not sleep! Do not block the reactor! Is asynchronous IO always possible at OS level? https://lwn.net/Articles/724198/
  • 12. Nicola Ferraro - JBCNConf Barcelona 2017 What’s wrong with “1 thread per request”? Performance comparison of Tomcat (1 thread per request) vs RxNetty (2015) Reasons: ● Thread migration + context switch ● Slower Garbage Collection Details: https://github.com/Netflix-Skunkworks/WSPerfLab /blob/master/test-results/RxNetty_vs_Tomcat_Apr il2015.pdf
  • 13. Nicola Ferraro - JBCNConf Barcelona 2017 Limits of “1 thread per request” model How many concurrent requests you can handle? 1 thread requires 1 MiB of stack memory by default 10k connections ~= 10 GiB of stack memory (just for the threads) What about the C10m problem? http://c10m.robertgraham.com/p/manifesto.html The C10k problem
  • 14. Nicola Ferraro - JBCNConf Barcelona 2017 Reactive Programming vs. Reactive Systems “Reactive: Readily responsive to a stimulus”, Merriam Webster ● Responsive (react to user requests): ○ Having rapid response times ● Resilient (react to failures) ○ Being responsive also in case of failures (e.g. replication, retry) ● Elastic (react to load) ○ No bottlenecks, can scale according to load ● Message driven (react to events/messages) ○ Communication based on asynchronous message passing, with location transparency and backpressure The reactive manifesto: http://www.reactivemanifesto.org/
  • 15. Nicola Ferraro - JBCNConf Barcelona 2017 Reactive “packages” PROJECT REACTOR (v. 5) Toolkits for building Reactive Systems Reactive Programming Frameworks Help me to classify them ... streams ?
  • 16. Nicola Ferraro - JBCNConf Barcelona 2017 Agenda ● What does it mean to be reactive? ○ Reactive Programming ○ Reactive Systems ● Application Integration ○ Enterprise Integration Patterns ○ Apache Camel ● Demo ● Integration in Reactive Systems ○ Patterns ○ Future Challenges
  • 17. Nicola Ferraro - JBCNConf Barcelona 2017 Integration Nobody lives in isolation. Integration is about: ● Communication (Messaging) ● Converting protocols ● Mapping Bounded Contexts ● Message Correlation ● Routing ● Flow Control ● ...
  • 18. Nicola Ferraro - JBCNConf Barcelona 2017 The integration platform Apache Camel is a powerful integration framework based on enterprise integration patterns! More than 200 components Can connect to any platform The new logo (proposal) by Zoran Regvart
  • 19. Nicola Ferraro - JBCNConf Barcelona 2017 Camel: the Components ahc, ahc-ws, amqp, apns, asterisk, atmos, atmosphere-websocket, atom, avro, aws, azure, bam, barcode, base64, beanio, beanstalk, bean-validator, bindy, blueprint, bonita, boon, box, braintree, cache, cassandraql, castor, cdi, chronicle, chunk, cmis, cm-sms, coap, cometd, consul, context, core-osgi, core-xml, couchbase, couchdb, crypto, csv, cxf, cxf-transport, digitalocean, disruptor, dns, docker, dozer, drill, dropbox, eclipse, ehcache, ejb, elasticsearch, elasticsearch5, elsql, etcd, eventadmin, exec, facebook, fastjson, firebase, flatpack, flink, fop, freemarker, ftp, ganglia, geocoder, git, github, google-calendar, google-drive, google-mail, google-pubsub, gora, grape, groovy, groovy-dsl, grpc, gson, guava-eventbus, guice, hawtdb, hazelcast, hbase, hdfs, hdfs2, headersmap, hessian, hipchat, hl7, http, http4, http-common, hystrix, ibatis, ical, ignite, infinispan, influxdb, irc, ironmq, jackson, jacksonxml, jasypt, javaspace, jaxb, jbpm, jcache, jclouds, jcr, jdbc, jetty, jetty9, jetty-common, jgroups, jibx, jing, jira, jms, jmx, johnzon, jolt, josql, jpa, jsch, jsonpath, jt400, juel, jxpath, kafka, kestrel, krati, kubernetes, kura, ldap, leveldb, linkedin, lucene, lumberjack, lzf, mail, metrics, milo, mina, mina2, mllp, mongodb, mongodb3, mongodb-gridfs, mqtt, msv, mustache, mvel, mybatis, nagios, nats, netty, netty4, netty4-http, netty-http, ognl, olingo2, olingo4, openshift, openstack, opentracing, optaplanner, paho, paxlogging, pdf, pgevent, printer, protobuf, pubnub, quartz, quartz2, quickfix, rabbitmq, reactive-streams, reactor, restlet, rest-swagger, ribbon, rmi, routebox, rss, ruby, rx, rxjava2, salesforce, sap-netweaver, saxon, scala, schematron, scr, script, servicenow, servlet, servletlistener, shiro, sip, sjms, sjms2, slack, smpp, snakeyaml, snmp, soap, solr, spark, spark-rest, splunk, spring, spring-batch, spring-boot, spring-cloud, spring-cloud-netflix, spring-dm, spring-integration, spring-javaconfig, spring-ldap, spring-redis, spring-security, spring-web, spring-ws, sql, ssh, stax, stomp, stream, stringtemplate, swagger, swagger-java, syslog, tagsoup, tarfile, telegram, test, test-blueprint, test-cdi, test-karaf, testng, test-spring, thrift, tika, twilio, twitter, undertow, univocity-parsers, urlrewrite, velocity, vertx, weather, websocket, xmlbeans, xmljson, xmlrpc, xmlsecurity, xmpp, xstream, yammer, zendesk, zipfile, zipkin, zookeeper, zookeeper-master …
  • 20. Nicola Ferraro - JBCNConf Barcelona 2017 Basic Usage // Simple routing from(“jms:queue/orders”) .log(“Processing order: ${body}”) .to(“http://myservice”) .to(“smtp:localhost:25”); Isn’t “.to()” close to “.map()”? // A (not so) much complicated // example from(“hdfs:/home/nicola/data”) .unmarshal().json() // json array .split().body() .choice() .when(...) .to(“jdbc:...”) .otherwise() .log(“Skipped ${body}”)
  • 21. Nicola Ferraro - JBCNConf Barcelona 2017 Camel: some EIPs Fix out of order messages Aggregating results in groups from(“...”).resequence(header(“timestamp”))... from(“...”).aggregate(header(“orderId”))...
  • 22. Nicola Ferraro - JBCNConf Barcelona 2017 Camel: some EIPs Recipient list Content Based Routing from(“...”).recipientList(header(“recipient”))... from(“...”).choice().when()...otherwise()
  • 23. Nicola Ferraro - JBCNConf Barcelona 2017 Camel: some EIPs Hystrix Others (important!): ● Redelivery Policy: setup number of redelivery attempts and delays ● Throttler: adjust message speed for slow consumers ● Service Call: integrate with an external service registry (consul, ribbon, kubernetes) ● Load Balancer: balance load to multiple endpoints using custom strategies from(“...”) .hystrix() .to(“http://service”) .onFallback() .transform()... Open and close the circuit to an external service and provide fallback responses to the client. S1 S2
  • 24. Nicola Ferraro - JBCNConf Barcelona 2017 Is Camel Reactive? Camel 3.0 will have a fully reactive core. Camel 2.20 is not fully reactive, but: ● Uses asynchronous processing by default (no 1 thread pr) ● Supports backpressure and throttling ● Has multiple components for asynchronous I/O No event loops and reactors, but it’s fast (especially the latest version)!
  • 25. Nicola Ferraro - JBCNConf Barcelona 2017 The goal: create a bigger reactive system Integration in Reactive Systems Browser (Vert.x) Microservice 1 (Vert.x) EventBus Microservice 2 (Vert.x) Resiliency, location transparency MS 1 MS 2 MS 3 MS 4 Another Reactive/Non-reactive Ecosystem Integration Microservice Integration Microservice Optional
  • 26. Nicola Ferraro - JBCNConf Barcelona 2017 Communication in Reactive Applications Inside the JVM: Reactive Streams http://www.reactive-streams.org/ A specification for asynchronous stream processing with non-blocking backpressure [?]. PROJECT REACTOR JVM Reactive Streams
  • 27. Nicola Ferraro - JBCNConf Barcelona 2017 Reactive Streams Visualized public interface Publisher<T> { public void subscribe(Subscriber<? super T> s); } public interface Subscriber<T> { public void onSubscribe(Subscription s); public void onNext(T t); public void onError(Throwable t); public void onComplete(); } public interface Subscription { public void request(long n); public void cancel(); } public interface Processor<T, R> extends Subscriber<T>, Publisher<R> { } Just this 4 interfaces (and the rules to use them). Java 9 Flow API: Flow.Publisher, Flow.Subscriber, Flow.Subscription, Flow.Processor
  • 28. Nicola Ferraro - JBCNConf Barcelona 2017 Agenda ● What does it mean to be reactive? ○ Reactive Programming ○ Reactive Systems ● Application Integration ○ Enterprise Integration Patterns ○ Apache Camel ● Demo ● Integration in Reactive Systems ○ Patterns ○ Future Challenges
  • 29. Nicola Ferraro - JBCNConf Barcelona 2017 Demo Use camel-reactive-streams to exchange data with a reactive library (Vert.x → rx-java2 → Camel). Use camel-netty-http to connect a Spring-Boot 2 (Spring 5) WebFlux service. Use camel-grpc to forward a stream to a remote service and get the response stream back. ● https://github.com/nicolaferraro/reactive-demo (note: requires camel 2.20-snapshot) PROJECT REACTOR
  • 30. Nicola Ferraro - JBCNConf Barcelona 2017 Demo: considerations I’ve used the generic camel-reactive-streams component but there’s also a specific connector for Vert.x (connects directly to the Eventbus): // Using the camel-vertx component from(“vertx:raw-points”) .to(“...”) .to(“vertx:enhanced-points”);
  • 31. Nicola Ferraro - JBCNConf Barcelona 2017 Agenda ● What does it mean to be reactive? ○ Reactive Programming ○ Reactive Systems ● Application Integration ○ Enterprise Integration Patterns ○ Apache Camel ● Demo ● Integration in Reactive Systems ○ Patterns ○ Future Challenges
  • 32. Nicola Ferraro - JBCNConf Barcelona 2017 Backpressure? OP Normal Scenario Normal operator or boundary betweeen reactive streams OP Too much water (events) SLOW buffer full pressure in the pipes (like with water!) Backpressure “Remember, you can’t put too much water in a nuclear reactor”, Saturday Night Live, 1984 buffer full Backpressure
  • 33. Nicola Ferraro - JBCNConf Barcelona 2017 Backpressure in Reactive Streams onSubscribe(sub) subscribe() request(1) onNext(“m1”) request(2) onNext(“m2”) onNext(“m3”) Publisher Subscriber
  • 34. Nicola Ferraro - JBCNConf Barcelona 2017 Limited Resources: microservices - no backpressure Microservice 1 Microservice 2 Microservice 3 Microservice 4 Can’t process all events: ● Timeout ● HTTP 503 In req/resp mode, you can do circuit breaking. In in-only (streaming) mode, you will retry (increase load)
  • 35. Nicola Ferraro - JBCNConf Barcelona 2017 Limited Resources: microservices with backpressure Microservice 1 Microservice 2 Microservice 4 Microservice 3You can buffer at the source! Flow control at system level backpressure Less responsive, but you can handle peaks Later, you can scale out “Microservice 4” to make the system more responsive
  • 36. Nicola Ferraro - JBCNConf Barcelona 2017 End-to-End Backpressure: In-Only Stream Java / JS / Python Service 1 Java / JS / Python Service 2 backpressured How??? RSocket http://rsocket.io/ Application protocol providing reactive streams semantics. Other solutions?? Designed for efficiency at low level onNext onError onComplete
  • 37. Nicola Ferraro - JBCNConf Barcelona 2017 End-to-End Backpressure: In-Only Stream This backpressure stuff is not new…
  • 38. Nicola Ferraro - JBCNConf Barcelona 2017 Back to TCP TPC implements a sliding window protocol for flow control! Java / JS / Python Java / JS / Python TCP / IP data ack + window size You cannot send more data than requested to a TCP recipient! TCP is backpressure aware!
  • 39. Nicola Ferraro - JBCNConf Barcelona 2017 Backpressure at Application Level: In-Only Stream App 1 TCP Local Backpressure: do not write too much App 2 TCP Local Backpressure: do not read if can’t process backpressured Application Level Backpressure Sliding window flow control Can work also with higher level protocols ● HTTP ● Websocket ● SSE ● gRPC End-to-end backpressure
  • 40. Nicola Ferraro - JBCNConf Barcelona 2017 Backpressure: Stream → Camel What in case of request/response messaging? Reactive Streams Rx-Java Camel from(“reactive-streams:events”) .throttle(3).timePeriodMillis(10000) .to(“http://dinosaurs.io/api/echo”); Camel Producer External Servicebackpressure from(“reactive-streams:events?maxInflightExchanges=20”) .to(“http://dinosaurs.io/api/echo”); No more than 20 concurrent reqsNo more than 3 reqs in 10 secs In-Out
  • 41. Nicola Ferraro - JBCNConf Barcelona 2017 Backpressure: Camel → Stream Camel Consumer Reactive Streams What happens when backpressure slows down Camel? Reactor-CoreCamel from(“jms:events”) .routePolicy(maxExchangesPolicy) .to(“reactive-streams:events”); Message Source backpressure Camel will pause the consumer in case of backpressure Flux<Message>
  • 42. Nicola Ferraro - JBCNConf Barcelona 2017 Adding Elasticity: Load Balancer canvas1 canvas2Camel Load Balancer: from(“...”) .loadBalance().sticky(canvasIdExpr()) .to(“endpoint1”, “endpoint2”) Supports: ● Round robin, random, custom ● Failover ● Mixing with ServiceCall EIP (location transparency + load balancing) Works with any protocol: HTTP, TCP, GRPC, ... Streams or RPC
  • 43. Nicola Ferraro - JBCNConf Barcelona 2017 Adding (a bit of) Location Transparency 192.168.0.22 service-1 service-2 Service Registry ● Consul ● Etcd ● Kubernetes ● Ribbon Camel ServiceCall EIP: from(“...”) .serviceCall(“service-2”) .to(“...”)
  • 44. Nicola Ferraro - JBCNConf Barcelona 2017 Adding Location Transparency and Resiliency Reactive Streams Rx-Java Camel Camel Producer Camel Consumer Messaging Broker (your choice) ● JMS ● Kafka (anti-backpressure) ● AMQP ● MQTT backpressure Allows all kind of messaging patterns: ● P2P In-Only ● P2P In-Out ● Pub/Sub Send messages to: ● Queues ● Topics backpressure If you have a fast-enough messaging broker, you don’t have to care a lot about backpressure when writing (anti-backpressure)
  • 45. Nicola Ferraro - JBCNConf Barcelona 2017 @ni_ferraro That’s all folks!