SlideShare a Scribd company logo
1 of 26
Download to read offline
Programming for cloud computing:
          Flows of asynchronous messages (swarms)


Sînică Alboaie (The Red Point S.A.) 2012,CodeCamp
Programming == Fight against complexity




Essential Complexity?
... and why should YOU care?


     "The Tao that can be spoken is not
                the eternal Tao" Lao Zi



 Loose coupling
 Single Responsibility Principle
 Separation of Concerns
 Open Closed principle

 Cloud Programming, Distributed and Parallel Systems
Point of view is worth 80 IQ points?


      In Roman time you had to be very smart
            to multiply two numbers together.
Cloud applications



● not a 'revolution'


● an evolution of the
  enterprise applications
Cloud computing exposes bad practices



    Isn't any different than traditional development.

● less tolerant of poor development
  practices
● attention to scalability and security
● don't relay on improving hardware
● no security through obscurity

!
Insights: Programming for the cloud

Money !?


●   Programming (new APIs, complexity)
●   Automation in deployment, configuration
●   New Type of Programmer: Dev-Op
●   Scalability (efficient use of hardware)
●   High availability (install/updates, failures)
●   Data consistency
Insights: Programming in cloud

Multitenancy

●   PaaS
●   iPaaS
●   ...aaS
●   Sharing and SLAs
●   Security
Cloud for normal budgets
● use quality open sources:
  ○ Redis, ZooKeeper, Message Queues
  ○ Hadoop, NoSQL Databases, etc
  ○ openstack, cloudfoundry


● node.js!

● Java,.net, php ?
● Amazon, Azure, Google ?
So...
What... SWARMING?
Swarm concepts

Nodes


● Cloud application == Forest
● Trees are processes
● Swarms are visiting trees (nodes)
Swarm concepts

Nodes


● Swarm's temporary destinations
● API providers (services)
● Adapters and Clients (web)
Swarm concepts
Swarm description




● variables (members)
● phases (code)
● "swarm" primitive
Swarm concepts
At runtime




Nothing special: Message passing!
Swarm description example
Hello world example, execution of 2 phases in 2 nodes:
Points of view
(Naive) messaging /Actors/ Erlang:
Nodes are sending typed messages to each other
Implicit: Flows are in programmer's minds
Application logic mixed in all nodes
Nodes are reacting to messages
Swarming:
Simpler code in nodes(APIs)
Explicit: Flows are described in files
Messages are flowing between nodes
Messages are causing changes in nodes
Usage: Enterprise Integration

Files, Databases
Point Point to point (Services/Messages)
Busses (Services/Messages)



       Code cd




SwarmESB
Usage: Cloud ready architecture




   Code cd




                     SwarmESB
Current implementation
●    node.js
●   Java Script and Flex clients
●   WebDAV proxy
●   SOLR adapter
●    Redis: pub/sub channels
    ○ messages
● Redis
    ○ multi-tenant storage
SwarmESB for you?



Familiarity!
Java Script + node.js
Vertical and horizontal scalability
Architect your new distributed system
Consume heterogeneous services (APIs)
Easy integration for future components
Parallel usage of your shiny, new CPU cores
Elegant programming with asynchronous messages
More coolness


●   multitenant global (redis) contexts
●   multitenant local (node) contexts
●   local sub-processes
●   swarm code redeployment without restart


Swarming can be for SOA's orchestration
              what REST is for SOAP!
Hackers and Hustlers
          Thank you!
Load balancer example
WorkerSwarm
1 ctor (doWork)
3 phases
● doChooseWorker
● executeWork
● taskDone
Load balancer example
WorkerManagment swarm
● Ctors:
  ○ register          [worker at start]
  ○ unregister        [worker at shutdown]
  ○ checkWorkerStatus [Balancer from time to time]


● Phases:
  ○   doRegister        [Balancer]
  ○   doUnegister      [Balancer]
  ○   statusCheck      [worker]
  ○   statusReport      [Balancer]
Keywords
SOA (Orchestration and choreography)
EAI (Enterprise Integration Patterns)
ESB (Enterprise Service Bus)
Events and Asynchronous Messages
PaaS ( Platform as a Service)
iPaaS (Cloud Integration)

More Related Content

What's hot

Amazon Web Services lection 5
Amazon Web Services lection 5  Amazon Web Services lection 5
Amazon Web Services lection 5 Binary Studio
 
Learning Kafka Streams with Scala
Learning Kafka Streams with ScalaLearning Kafka Streams with Scala
Learning Kafka Streams with ScalaKnoldus Inc.
 
Getting Started with Serverless PHP
Getting Started with Serverless PHPGetting Started with Serverless PHP
Getting Started with Serverless PHPAndrew Raines
 
Scylla Summit 2022: Overcoming the Performance Cost of Streaming Transactions
Scylla Summit 2022: Overcoming the Performance Cost of Streaming TransactionsScylla Summit 2022: Overcoming the Performance Cost of Streaming Transactions
Scylla Summit 2022: Overcoming the Performance Cost of Streaming TransactionsScyllaDB
 
Long running aws lambda - Joel Schuweiler, Minneapolis
Long running aws lambda -  Joel Schuweiler, MinneapolisLong running aws lambda -  Joel Schuweiler, Minneapolis
Long running aws lambda - Joel Schuweiler, MinneapolisAWS Chicago
 
PyConIE 2017 Writing and deploying serverless python applications
PyConIE 2017 Writing and deploying serverless python applicationsPyConIE 2017 Writing and deploying serverless python applications
PyConIE 2017 Writing and deploying serverless python applicationsCesar Cardenas Desales
 
SIGGRAPH Presentation 2016 Slides
SIGGRAPH Presentation 2016 SlidesSIGGRAPH Presentation 2016 Slides
SIGGRAPH Presentation 2016 SlidesAaron Carey
 
Introduction to Apache Cassandra
Introduction to Apache CassandraIntroduction to Apache Cassandra
Introduction to Apache CassandraIntan Marselly
 
Writing and deploying serverless python applications
Writing and deploying serverless python applicationsWriting and deploying serverless python applications
Writing and deploying serverless python applicationsCesar Cardenas Desales
 
S3, Cassandra or Outer Space? Dumping Time Series Data using Spark - Demi Be...
S3, Cassandra or Outer Space? Dumping Time Series Data using Spark  - Demi Be...S3, Cassandra or Outer Space? Dumping Time Series Data using Spark  - Demi Be...
S3, Cassandra or Outer Space? Dumping Time Series Data using Spark - Demi Be...Codemotion
 
PyConIT 2018 Writing and deploying serverless python applications
PyConIT 2018 Writing and deploying serverless python applicationsPyConIT 2018 Writing and deploying serverless python applications
PyConIT 2018 Writing and deploying serverless python applicationsCesar Cardenas Desales
 
Air traffic controller - Streams Processing meetup
Air traffic controller  - Streams Processing meetupAir traffic controller  - Streams Processing meetup
Air traffic controller - Streams Processing meetupEd Yakabosky
 
Netflix Keystone - How Netflix Handles Data Streams up to 11M Events/Sec
Netflix Keystone - How Netflix Handles Data Streams up to 11M Events/SecNetflix Keystone - How Netflix Handles Data Streams up to 11M Events/Sec
Netflix Keystone - How Netflix Handles Data Streams up to 11M Events/SecPeter Bakas
 
X-Ray distributed tracing proof-of-concept
X-Ray distributed tracing proof-of-conceptX-Ray distributed tracing proof-of-concept
X-Ray distributed tracing proof-of-conceptAram Alipoor
 
Touch serverless with Java and AWS
Touch serverless with Java and AWSTouch serverless with Java and AWS
Touch serverless with Java and AWSPaweł Janusz
 
Communication tool & Environment for Remote Worker
Communication tool & Environment for Remote WorkerCommunication tool & Environment for Remote Worker
Communication tool & Environment for Remote WorkerShotaro Sakamaki
 
Stream processing using Apache Storm - Big Data Meetup Athens 2016
Stream processing using Apache Storm - Big Data Meetup Athens 2016Stream processing using Apache Storm - Big Data Meetup Athens 2016
Stream processing using Apache Storm - Big Data Meetup Athens 2016Adrianos Dadis
 
Harvesting the Power of Samza in LinkedIn's Feed
Harvesting the Power of Samza in LinkedIn's FeedHarvesting the Power of Samza in LinkedIn's Feed
Harvesting the Power of Samza in LinkedIn's FeedMohamed El-Geish
 

What's hot (20)

Amazon Web Services lection 5
Amazon Web Services lection 5  Amazon Web Services lection 5
Amazon Web Services lection 5
 
Learning Kafka Streams with Scala
Learning Kafka Streams with ScalaLearning Kafka Streams with Scala
Learning Kafka Streams with Scala
 
Getting Started with Serverless PHP
Getting Started with Serverless PHPGetting Started with Serverless PHP
Getting Started with Serverless PHP
 
Scylla Summit 2022: Overcoming the Performance Cost of Streaming Transactions
Scylla Summit 2022: Overcoming the Performance Cost of Streaming TransactionsScylla Summit 2022: Overcoming the Performance Cost of Streaming Transactions
Scylla Summit 2022: Overcoming the Performance Cost of Streaming Transactions
 
Long running aws lambda - Joel Schuweiler, Minneapolis
Long running aws lambda -  Joel Schuweiler, MinneapolisLong running aws lambda -  Joel Schuweiler, Minneapolis
Long running aws lambda - Joel Schuweiler, Minneapolis
 
PyConIE 2017 Writing and deploying serverless python applications
PyConIE 2017 Writing and deploying serverless python applicationsPyConIE 2017 Writing and deploying serverless python applications
PyConIE 2017 Writing and deploying serverless python applications
 
SIGGRAPH Presentation 2016 Slides
SIGGRAPH Presentation 2016 SlidesSIGGRAPH Presentation 2016 Slides
SIGGRAPH Presentation 2016 Slides
 
Introduction to Apache Cassandra
Introduction to Apache CassandraIntroduction to Apache Cassandra
Introduction to Apache Cassandra
 
Writing and deploying serverless python applications
Writing and deploying serverless python applicationsWriting and deploying serverless python applications
Writing and deploying serverless python applications
 
S3, Cassandra or Outer Space? Dumping Time Series Data using Spark - Demi Be...
S3, Cassandra or Outer Space? Dumping Time Series Data using Spark  - Demi Be...S3, Cassandra or Outer Space? Dumping Time Series Data using Spark  - Demi Be...
S3, Cassandra or Outer Space? Dumping Time Series Data using Spark - Demi Be...
 
PyConIT 2018 Writing and deploying serverless python applications
PyConIT 2018 Writing and deploying serverless python applicationsPyConIT 2018 Writing and deploying serverless python applications
PyConIT 2018 Writing and deploying serverless python applications
 
Air traffic controller - Streams Processing meetup
Air traffic controller  - Streams Processing meetupAir traffic controller  - Streams Processing meetup
Air traffic controller - Streams Processing meetup
 
Netflix Keystone - How Netflix Handles Data Streams up to 11M Events/Sec
Netflix Keystone - How Netflix Handles Data Streams up to 11M Events/SecNetflix Keystone - How Netflix Handles Data Streams up to 11M Events/Sec
Netflix Keystone - How Netflix Handles Data Streams up to 11M Events/Sec
 
Netty training
Netty trainingNetty training
Netty training
 
X-Ray distributed tracing proof-of-concept
X-Ray distributed tracing proof-of-conceptX-Ray distributed tracing proof-of-concept
X-Ray distributed tracing proof-of-concept
 
Touch serverless with Java and AWS
Touch serverless with Java and AWSTouch serverless with Java and AWS
Touch serverless with Java and AWS
 
Communication tool & Environment for Remote Worker
Communication tool & Environment for Remote WorkerCommunication tool & Environment for Remote Worker
Communication tool & Environment for Remote Worker
 
Stream processing using Apache Storm - Big Data Meetup Athens 2016
Stream processing using Apache Storm - Big Data Meetup Athens 2016Stream processing using Apache Storm - Big Data Meetup Athens 2016
Stream processing using Apache Storm - Big Data Meetup Athens 2016
 
Harvesting the Power of Samza in LinkedIn's Feed
Harvesting the Power of Samza in LinkedIn's FeedHarvesting the Power of Samza in LinkedIn's Feed
Harvesting the Power of Samza in LinkedIn's Feed
 
Pre fosdem2020 uber
Pre fosdem2020 uberPre fosdem2020 uber
Pre fosdem2020 uber
 

Viewers also liked

Programming Languages For The Cloud
Programming Languages For The CloudProgramming Languages For The Cloud
Programming Languages For The CloudTed Leung
 
Spurious correlation (updated)
Spurious correlation (updated)Spurious correlation (updated)
Spurious correlation (updated)jemille6
 
HDFS for Geographically Distributed File System
HDFS for Geographically Distributed File SystemHDFS for Geographically Distributed File System
HDFS for Geographically Distributed File SystemKonstantin V. Shvachko
 
Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...
Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...
Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...jemille6
 
A secure cloud computing based framework for big data information management ...
A secure cloud computing based framework for big data information management ...A secure cloud computing based framework for big data information management ...
A secure cloud computing based framework for big data information management ...Nexgen Technology
 
T8 hypothesis testing
T8 hypothesis testingT8 hypothesis testing
T8 hypothesis testingkompellark
 
Severe Testing: The Key to Error Correction
Severe Testing: The Key to Error CorrectionSevere Testing: The Key to Error Correction
Severe Testing: The Key to Error Correctionjemille6
 
A secure cloud computing based framework for big information management syste...
A secure cloud computing based framework for big information management syste...A secure cloud computing based framework for big information management syste...
A secure cloud computing based framework for big information management syste...Pawan Arya
 
SmartGrid System Report
SmartGrid System ReportSmartGrid System Report
SmartGrid System ReportGruene-it.org
 
Smart Grid - An Outline
Smart Grid - An OutlineSmart Grid - An Outline
Smart Grid - An OutlineShyam Penubolu
 
Selective Data Replication with Geographically Distributed Hadoop
Selective Data Replication with Geographically Distributed HadoopSelective Data Replication with Geographically Distributed Hadoop
Selective Data Replication with Geographically Distributed HadoopDataWorks Summit
 
Test of hypothesis
Test of hypothesisTest of hypothesis
Test of hypothesisvikramlawand
 
Hypothesis testing ppt final
Hypothesis testing ppt finalHypothesis testing ppt final
Hypothesis testing ppt finalpiyushdhaker
 
Smart Grid Introduction
Smart Grid Introduction Smart Grid Introduction
Smart Grid Introduction Nilesh Dhage
 

Viewers also liked (16)

Programming Languages For The Cloud
Programming Languages For The CloudProgramming Languages For The Cloud
Programming Languages For The Cloud
 
Spurious correlation (updated)
Spurious correlation (updated)Spurious correlation (updated)
Spurious correlation (updated)
 
HDFS for Geographically Distributed File System
HDFS for Geographically Distributed File SystemHDFS for Geographically Distributed File System
HDFS for Geographically Distributed File System
 
Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...
Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...
Surrogate Science: How Fisher, Neyman-Pearson, and Bayes Were Transformed int...
 
A secure cloud computing based framework for big data information management ...
A secure cloud computing based framework for big data information management ...A secure cloud computing based framework for big data information management ...
A secure cloud computing based framework for big data information management ...
 
T8 hypothesis testing
T8 hypothesis testingT8 hypothesis testing
T8 hypothesis testing
 
Severe Testing: The Key to Error Correction
Severe Testing: The Key to Error CorrectionSevere Testing: The Key to Error Correction
Severe Testing: The Key to Error Correction
 
A secure cloud computing based framework for big information management syste...
A secure cloud computing based framework for big information management syste...A secure cloud computing based framework for big information management syste...
A secure cloud computing based framework for big information management syste...
 
SmartGrid System Report
SmartGrid System ReportSmartGrid System Report
SmartGrid System Report
 
Smart Grid - An Outline
Smart Grid - An OutlineSmart Grid - An Outline
Smart Grid - An Outline
 
Selective Data Replication with Geographically Distributed Hadoop
Selective Data Replication with Geographically Distributed HadoopSelective Data Replication with Geographically Distributed Hadoop
Selective Data Replication with Geographically Distributed Hadoop
 
Smart Grid Technology
Smart Grid TechnologySmart Grid Technology
Smart Grid Technology
 
Test of hypothesis
Test of hypothesisTest of hypothesis
Test of hypothesis
 
Hypothesis testing ppt final
Hypothesis testing ppt finalHypothesis testing ppt final
Hypothesis testing ppt final
 
Smart Grid Introduction
Smart Grid Introduction Smart Grid Introduction
Smart Grid Introduction
 
Smart grid ppt
Smart grid pptSmart grid ppt
Smart grid ppt
 

Similar to Sînică Alboaie - Programming for cloud computing Flows of asynchronous messages

NoSQL design pitfalls with Java
NoSQL design pitfalls with JavaNoSQL design pitfalls with Java
NoSQL design pitfalls with JavaOtávio Santana
 
AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020
AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020
AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020Tim Wagner
 
Skillenza Build with Serverless Challenge - Advanced Serverless Concepts
Skillenza Build with Serverless Challenge -  Advanced Serverless ConceptsSkillenza Build with Serverless Challenge -  Advanced Serverless Concepts
Skillenza Build with Serverless Challenge - Advanced Serverless ConceptsDhaval Nagar
 
Scala Days Highlights | BoldRadius
Scala Days Highlights | BoldRadiusScala Days Highlights | BoldRadius
Scala Days Highlights | BoldRadiusBoldRadius Solutions
 
[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...
[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...
[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...Srijan Technologies
 
AWS vs Azure vs Google (GCP) - Slides
AWS vs Azure vs Google (GCP) - SlidesAWS vs Azure vs Google (GCP) - Slides
AWS vs Azure vs Google (GCP) - SlidesTobyWilman
 
Simon Peyton Jones: Managing parallelism
Simon Peyton Jones: Managing parallelismSimon Peyton Jones: Managing parallelism
Simon Peyton Jones: Managing parallelismSkills Matter
 
Peyton jones-2011-parallel haskell-the_future
Peyton jones-2011-parallel haskell-the_futurePeyton jones-2011-parallel haskell-the_future
Peyton jones-2011-parallel haskell-the_futureTakayuki Muranushi
 
A performance analysis of OpenStack Cloud vs Real System on Hadoop Clusters
A performance analysis of OpenStack Cloud vs Real System on Hadoop ClustersA performance analysis of OpenStack Cloud vs Real System on Hadoop Clusters
A performance analysis of OpenStack Cloud vs Real System on Hadoop ClustersKumari Surabhi
 
Future of Cloud Starts with Serverless
Future of Cloud Starts with ServerlessFuture of Cloud Starts with Serverless
Future of Cloud Starts with ServerlessAntoni Orfin
 
Intro to big data analytics using microsoft machine learning server with spark
Intro to big data analytics using microsoft machine learning server with sparkIntro to big data analytics using microsoft machine learning server with spark
Intro to big data analytics using microsoft machine learning server with sparkAlex Zeltov
 
What is Mean Stack Development ?
What is Mean Stack Development ?What is Mean Stack Development ?
What is Mean Stack Development ?Balajihope
 
Scalability challenges
Scalability challengesScalability challenges
Scalability challengesAhmed Atef
 
Scaling for Performance
Scaling for PerformanceScaling for Performance
Scaling for PerformanceScyllaDB
 
Building and deploying LLM applications with Apache Airflow
Building and deploying LLM applications with Apache AirflowBuilding and deploying LLM applications with Apache Airflow
Building and deploying LLM applications with Apache AirflowKaxil Naik
 

Similar to Sînică Alboaie - Programming for cloud computing Flows of asynchronous messages (20)

Swarms: introduction
Swarms: introductionSwarms: introduction
Swarms: introduction
 
NoSQL design pitfalls with Java
NoSQL design pitfalls with JavaNoSQL design pitfalls with Java
NoSQL design pitfalls with Java
 
AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020
AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020
AWS Serverless Community Day Keynote and Vendia Launch 6-26-2020
 
Skillenza Build with Serverless Challenge - Advanced Serverless Concepts
Skillenza Build with Serverless Challenge -  Advanced Serverless ConceptsSkillenza Build with Serverless Challenge -  Advanced Serverless Concepts
Skillenza Build with Serverless Challenge - Advanced Serverless Concepts
 
Nodejs
NodejsNodejs
Nodejs
 
Scala Days Highlights | BoldRadius
Scala Days Highlights | BoldRadiusScala Days Highlights | BoldRadius
Scala Days Highlights | BoldRadius
 
[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...
[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...
[Srijan Wednesday Webinars] How to Build a Cloud Native Platform for Enterpri...
 
AWS vs Azure vs Google (GCP) - Slides
AWS vs Azure vs Google (GCP) - SlidesAWS vs Azure vs Google (GCP) - Slides
AWS vs Azure vs Google (GCP) - Slides
 
Simon Peyton Jones: Managing parallelism
Simon Peyton Jones: Managing parallelismSimon Peyton Jones: Managing parallelism
Simon Peyton Jones: Managing parallelism
 
Peyton jones-2011-parallel haskell-the_future
Peyton jones-2011-parallel haskell-the_futurePeyton jones-2011-parallel haskell-the_future
Peyton jones-2011-parallel haskell-the_future
 
A performance analysis of OpenStack Cloud vs Real System on Hadoop Clusters
A performance analysis of OpenStack Cloud vs Real System on Hadoop ClustersA performance analysis of OpenStack Cloud vs Real System on Hadoop Clusters
A performance analysis of OpenStack Cloud vs Real System on Hadoop Clusters
 
Future of Cloud Starts with Serverless
Future of Cloud Starts with ServerlessFuture of Cloud Starts with Serverless
Future of Cloud Starts with Serverless
 
NoSQL and ACID
NoSQL and ACIDNoSQL and ACID
NoSQL and ACID
 
Intro to big data analytics using microsoft machine learning server with spark
Intro to big data analytics using microsoft machine learning server with sparkIntro to big data analytics using microsoft machine learning server with spark
Intro to big data analytics using microsoft machine learning server with spark
 
Ml2
Ml2Ml2
Ml2
 
What is Mean Stack Development ?
What is Mean Stack Development ?What is Mean Stack Development ?
What is Mean Stack Development ?
 
Scalability challenges
Scalability challengesScalability challenges
Scalability challenges
 
Scaling for Performance
Scaling for PerformanceScaling for Performance
Scaling for Performance
 
Building and deploying LLM applications with Apache Airflow
Building and deploying LLM applications with Apache AirflowBuilding and deploying LLM applications with Apache Airflow
Building and deploying LLM applications with Apache Airflow
 
Beginners Node.js
Beginners Node.jsBeginners Node.js
Beginners Node.js
 

More from Codecamp Romania

Cezar chitac the edge of experience
Cezar chitac   the edge of experienceCezar chitac   the edge of experience
Cezar chitac the edge of experienceCodecamp Romania
 
Business analysis techniques exercise your 6-pack
Business analysis techniques   exercise your 6-packBusiness analysis techniques   exercise your 6-pack
Business analysis techniques exercise your 6-packCodecamp Romania
 
Bpm company code camp - configuration or coding with pega
Bpm company   code camp - configuration or coding with pegaBpm company   code camp - configuration or coding with pega
Bpm company code camp - configuration or coding with pegaCodecamp Romania
 
Andrei prisacaru takingtheunitteststothedatabase
Andrei prisacaru takingtheunitteststothedatabaseAndrei prisacaru takingtheunitteststothedatabase
Andrei prisacaru takingtheunitteststothedatabaseCodecamp Romania
 
2015 dan ardelean develop for windows 10
2015 dan ardelean   develop for windows 10 2015 dan ardelean   develop for windows 10
2015 dan ardelean develop for windows 10 Codecamp Romania
 
The case for continuous delivery
The case for continuous deliveryThe case for continuous delivery
The case for continuous deliveryCodecamp Romania
 
Stefan stolniceanu spritekit, 2 d or not 2d
Stefan stolniceanu   spritekit, 2 d or not 2dStefan stolniceanu   spritekit, 2 d or not 2d
Stefan stolniceanu spritekit, 2 d or not 2dCodecamp Romania
 
Sizing epics tales from an agile kingdom
Sizing epics   tales from an agile kingdomSizing epics   tales from an agile kingdom
Sizing epics tales from an agile kingdomCodecamp Romania
 
Raluca butnaru corina cilibiu the unknown universe of a product and the cer...
Raluca butnaru corina cilibiu   the unknown universe of a product and the cer...Raluca butnaru corina cilibiu   the unknown universe of a product and the cer...
Raluca butnaru corina cilibiu the unknown universe of a product and the cer...Codecamp Romania
 
Parallel & async processing using tpl dataflow
Parallel & async processing using tpl dataflowParallel & async processing using tpl dataflow
Parallel & async processing using tpl dataflowCodecamp Romania
 
Material design screen transitions in android
Material design screen transitions in androidMaterial design screen transitions in android
Material design screen transitions in androidCodecamp Romania
 
Kickstart your own freelancing career
Kickstart your own freelancing careerKickstart your own freelancing career
Kickstart your own freelancing careerCodecamp Romania
 
Ionut grecu the soft stuff is the hard stuff. the agile soft skills toolkit
Ionut grecu   the soft stuff is the hard stuff. the agile soft skills toolkitIonut grecu   the soft stuff is the hard stuff. the agile soft skills toolkit
Ionut grecu the soft stuff is the hard stuff. the agile soft skills toolkitCodecamp Romania
 
Diana antohi me against myself or how to fail and move forward
Diana antohi   me against myself  or how to fail  and move forwardDiana antohi   me against myself  or how to fail  and move forward
Diana antohi me against myself or how to fail and move forwardCodecamp Romania
 

More from Codecamp Romania (20)

Cezar chitac the edge of experience
Cezar chitac   the edge of experienceCezar chitac   the edge of experience
Cezar chitac the edge of experience
 
Cloud powered search
Cloud powered searchCloud powered search
Cloud powered search
 
Ccp
CcpCcp
Ccp
 
Business analysis techniques exercise your 6-pack
Business analysis techniques   exercise your 6-packBusiness analysis techniques   exercise your 6-pack
Business analysis techniques exercise your 6-pack
 
Bpm company code camp - configuration or coding with pega
Bpm company   code camp - configuration or coding with pegaBpm company   code camp - configuration or coding with pega
Bpm company code camp - configuration or coding with pega
 
Andrei prisacaru takingtheunitteststothedatabase
Andrei prisacaru takingtheunitteststothedatabaseAndrei prisacaru takingtheunitteststothedatabase
Andrei prisacaru takingtheunitteststothedatabase
 
Agility and life
Agility and lifeAgility and life
Agility and life
 
2015 dan ardelean develop for windows 10
2015 dan ardelean   develop for windows 10 2015 dan ardelean   develop for windows 10
2015 dan ardelean develop for windows 10
 
The bigrewrite
The bigrewriteThe bigrewrite
The bigrewrite
 
The case for continuous delivery
The case for continuous deliveryThe case for continuous delivery
The case for continuous delivery
 
Stefan stolniceanu spritekit, 2 d or not 2d
Stefan stolniceanu   spritekit, 2 d or not 2dStefan stolniceanu   spritekit, 2 d or not 2d
Stefan stolniceanu spritekit, 2 d or not 2d
 
Sizing epics tales from an agile kingdom
Sizing epics   tales from an agile kingdomSizing epics   tales from an agile kingdom
Sizing epics tales from an agile kingdom
 
Scale net apps in aws
Scale net apps in awsScale net apps in aws
Scale net apps in aws
 
Raluca butnaru corina cilibiu the unknown universe of a product and the cer...
Raluca butnaru corina cilibiu   the unknown universe of a product and the cer...Raluca butnaru corina cilibiu   the unknown universe of a product and the cer...
Raluca butnaru corina cilibiu the unknown universe of a product and the cer...
 
Parallel & async processing using tpl dataflow
Parallel & async processing using tpl dataflowParallel & async processing using tpl dataflow
Parallel & async processing using tpl dataflow
 
Material design screen transitions in android
Material design screen transitions in androidMaterial design screen transitions in android
Material design screen transitions in android
 
Kickstart your own freelancing career
Kickstart your own freelancing careerKickstart your own freelancing career
Kickstart your own freelancing career
 
Ionut grecu the soft stuff is the hard stuff. the agile soft skills toolkit
Ionut grecu   the soft stuff is the hard stuff. the agile soft skills toolkitIonut grecu   the soft stuff is the hard stuff. the agile soft skills toolkit
Ionut grecu the soft stuff is the hard stuff. the agile soft skills toolkit
 
Ecma6 in the wild
Ecma6 in the wildEcma6 in the wild
Ecma6 in the wild
 
Diana antohi me against myself or how to fail and move forward
Diana antohi   me against myself  or how to fail  and move forwardDiana antohi   me against myself  or how to fail  and move forward
Diana antohi me against myself or how to fail and move forward
 

Sînică Alboaie - Programming for cloud computing Flows of asynchronous messages

  • 1.
  • 2. Programming for cloud computing: Flows of asynchronous messages (swarms) Sînică Alboaie (The Red Point S.A.) 2012,CodeCamp
  • 3. Programming == Fight against complexity Essential Complexity?
  • 4. ... and why should YOU care? "The Tao that can be spoken is not the eternal Tao" Lao Zi Loose coupling Single Responsibility Principle Separation of Concerns Open Closed principle Cloud Programming, Distributed and Parallel Systems
  • 5. Point of view is worth 80 IQ points? In Roman time you had to be very smart to multiply two numbers together.
  • 6. Cloud applications ● not a 'revolution' ● an evolution of the enterprise applications
  • 7. Cloud computing exposes bad practices Isn't any different than traditional development. ● less tolerant of poor development practices ● attention to scalability and security ● don't relay on improving hardware ● no security through obscurity !
  • 8. Insights: Programming for the cloud Money !? ● Programming (new APIs, complexity) ● Automation in deployment, configuration ● New Type of Programmer: Dev-Op ● Scalability (efficient use of hardware) ● High availability (install/updates, failures) ● Data consistency
  • 9. Insights: Programming in cloud Multitenancy ● PaaS ● iPaaS ● ...aaS ● Sharing and SLAs ● Security
  • 10. Cloud for normal budgets ● use quality open sources: ○ Redis, ZooKeeper, Message Queues ○ Hadoop, NoSQL Databases, etc ○ openstack, cloudfoundry ● node.js! ● Java,.net, php ? ● Amazon, Azure, Google ?
  • 12. Swarm concepts Nodes ● Cloud application == Forest ● Trees are processes ● Swarms are visiting trees (nodes)
  • 13. Swarm concepts Nodes ● Swarm's temporary destinations ● API providers (services) ● Adapters and Clients (web)
  • 14. Swarm concepts Swarm description ● variables (members) ● phases (code) ● "swarm" primitive
  • 15. Swarm concepts At runtime Nothing special: Message passing!
  • 16. Swarm description example Hello world example, execution of 2 phases in 2 nodes:
  • 17. Points of view (Naive) messaging /Actors/ Erlang: Nodes are sending typed messages to each other Implicit: Flows are in programmer's minds Application logic mixed in all nodes Nodes are reacting to messages Swarming: Simpler code in nodes(APIs) Explicit: Flows are described in files Messages are flowing between nodes Messages are causing changes in nodes
  • 18. Usage: Enterprise Integration Files, Databases Point Point to point (Services/Messages) Busses (Services/Messages) Code cd SwarmESB
  • 19. Usage: Cloud ready architecture Code cd SwarmESB
  • 20. Current implementation ● node.js ● Java Script and Flex clients ● WebDAV proxy ● SOLR adapter ● Redis: pub/sub channels ○ messages ● Redis ○ multi-tenant storage
  • 21. SwarmESB for you? Familiarity! Java Script + node.js Vertical and horizontal scalability Architect your new distributed system Consume heterogeneous services (APIs) Easy integration for future components Parallel usage of your shiny, new CPU cores Elegant programming with asynchronous messages
  • 22. More coolness ● multitenant global (redis) contexts ● multitenant local (node) contexts ● local sub-processes ● swarm code redeployment without restart Swarming can be for SOA's orchestration what REST is for SOAP!
  • 23. Hackers and Hustlers Thank you!
  • 24. Load balancer example WorkerSwarm 1 ctor (doWork) 3 phases ● doChooseWorker ● executeWork ● taskDone
  • 25. Load balancer example WorkerManagment swarm ● Ctors: ○ register [worker at start] ○ unregister [worker at shutdown] ○ checkWorkerStatus [Balancer from time to time] ● Phases: ○ doRegister [Balancer] ○ doUnegister [Balancer] ○ statusCheck [worker] ○ statusReport [Balancer]
  • 26. Keywords SOA (Orchestration and choreography) EAI (Enterprise Integration Patterns) ESB (Enterprise Service Bus) Events and Asynchronous Messages PaaS ( Platform as a Service) iPaaS (Cloud Integration)