SlideShare una empresa de Scribd logo
1 de 33
Typesafe Stack Software
Development On The JVM

Sushanta Pradhan
Talentica Software (I) Pvt. Ltd.
History of Hardware Architecture

•   Single core era
    • moore's law achieved by increasing clock cycles

•   Multi core era
    • moore's law achieved by increasing # of cores
Moore’s Law
PPP – Grand Challenge
•   Parallel programming as easy as sequential
    programming
•   Moores’s law of performance – speed up 2 times year
    on year
•   Eliminate concurrency bugs
History of software applications
 • pre .com era
   • standalone desktop apps
 • .com era
   • web sites - static web pages, automated business
      processes
   • data controlled by software vendor
   • deployed on data centers
contd ..
 •   web2.0/semantic web era
     • web/networked applications
     • Smart apps
     • data not controlled by vendor but by the users
     • deployed on cloud
Properties of modern day App
•   Scalability
•   Distributed
•   Parallel & Concurrent
•   Dynamic
•   Agile & Swift
Parallelism & Concurrency
 •   Parallel Programming
     • parallel execution of programs
     • can't be performed without parallel hardware
     • programs get faster
Parallelism & Concurrency
•   Concurrent Programming
    • simultaneous execution of programs
    • can be performed without parallel hardware
    • programs get more responsive

Both are too hard !!
Why Hard?

•   non-determinism due to shared mutable state by
    concurrent threads
•   encapsulate state in actors or transactors but fundamental
    problems still remains

    non-determinism = parallel processing + mutable state
Remedy?
       PREVENTION IS BETTER THAN CURE !!

 •   Avoid mutable state and get deterministic processing

 •   Which means program functionally
Space vs Time
Space(functional/parallel)




    Time(imperative/concurrent)
Scala
•   Hybrid – functional & object oriented (pure)
•   strong static typing
•   Agile - concise & expressive
•   Parallel & Sequential
•   intermixes well with Java
Scala contd ..

  Parallellism
  • parallel collections
  • distributed collections
  Concurrency
  • Actors
  • STM              Akka
  • Futures
Scala contd ..

•   Concise Java
•   Immutability Val & Var
•   Tuples & Multiple Assignments
•   Sensible Defaults
•   Operator Overloading
Scala classes ..
•   Terse
•   Object keyword - Singleton
•   Companion Objects
•   Type inference
•   Option[T] – Some[T], None
Class hierarchy
Scala – Functional Aspects
•   Functions too are objects
•   Higher Order Functions
•   Partially applied Functions
•   Closures
Scala Inehritance
•   Traits
•   Mixins
•   Type inference - implicit keyword
Scala collections
•   Mutable & immutable
•   filter()
•   Map()
•   foldLeft()
•   foldRight()
Scala – Pattern Matching
•   Advanced switch case
•   Literals and constants
•   WildCards
•   Tuples & Lists
•   Guards
•   Regular Expressions
Scala - Concurrency
•   actor()
•   Actor Class
•   receive() & recieveWithin()
•   react() & reachWithin()
•   loop() & loopwhile()
Akka - Middleware
•   Concurrent, Scalable & fault-tolerant
•   based on actor model
•   highly performant
•   event driven
•   location transparency
Actor system
•   ensemble of actors sharing common configuration
•   hierarchical structure
•   heavyweight
•   has its own pool of resources threads
Supervision
•   dependency relationship between actors
•   supervisor - subordinate model
•   supervisor monitors and reacts to any errors reported
    by subordinates
•   configurable supervision strategy
•   lifecycle monitoring
Supervision hierarchy




                                ”root guardian”

                        ”guardian”
             shutdown                    “system
         guardian”
                                order
Remoting
•   ActorPath
    • purely local - "akka://my-sys/user/service-a/worker1"
    • local or remote - "akka://my-sys@host.example.com:5678
                   /user/service-b"

•   Seamlessly send messages to actors on remote nodes
Routing
•   route messages to actors(routees)
•   ideal for load balancing
•   Examples
    • RoundRobinRouter
    • RandomRouter
    • SmallestMailboxRouter
    • BroadcastRouter
Dispatchers
•   make akka actors tick
•   manages the resources(threads) used by actors
•   configure mailboxes of actors
•   Examples
    • fork-join-executor
    • thread-pool-executor
Play
•   ruby on rails like agility
•   convention over configuration
•   seamless integration with akka for scalability
•   edit and test
Play contd ..
 •   an easy, out-of-the-box setup for unit and functional testing
 •   asynchronous HTTP request handling
 •   WebSocket support
 •   cache support (e.g. memcached)
 •   integrated JSON and XML handling
Progressive Stream Processing
•   Iteratees
•   Enumerators
•   Enumeratees
Q/A

Más contenido relacionado

La actualidad más candente

Display earthquakes with Akka-http
Display earthquakes with Akka-httpDisplay earthquakes with Akka-http
Display earthquakes with Akka-httpPierangelo Cecchetto
 
JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?
JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?
JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?PROIDEA
 
Flying to clouds - can it be easy? Cloud Native Applications
Flying to clouds - can it be easy? Cloud Native ApplicationsFlying to clouds - can it be easy? Cloud Native Applications
Flying to clouds - can it be easy? Cloud Native ApplicationsJacek Bukowski
 
Rainbows, Unicorns, and other Fairy Tales in the Land of Serverless Dreams
Rainbows, Unicorns, and other Fairy Tales in the Land of Serverless DreamsRainbows, Unicorns, and other Fairy Tales in the Land of Serverless Dreams
Rainbows, Unicorns, and other Fairy Tales in the Land of Serverless DreamsJosh Carlisle
 
The 6 Rules for Modernizing Your Legacy Java Monolith with Microservices
The 6 Rules for Modernizing Your Legacy Java Monolith with MicroservicesThe 6 Rules for Modernizing Your Legacy Java Monolith with Microservices
The 6 Rules for Modernizing Your Legacy Java Monolith with MicroservicesLightbend
 
Getting ready to java 8
Getting ready to java 8Getting ready to java 8
Getting ready to java 8DataArt
 
Getting ready to java 8
Getting ready to java 8Getting ready to java 8
Getting ready to java 8Strannik_2013
 
Training on iOS app development - Samesh Swongamikha & Neetin Sharma
Training on iOS app development - Samesh Swongamikha & Neetin SharmaTraining on iOS app development - Samesh Swongamikha & Neetin Sharma
Training on iOS app development - Samesh Swongamikha & Neetin SharmaMobileNepal
 
Apache Zeppelin & Cluster
Apache Zeppelin & ClusterApache Zeppelin & Cluster
Apache Zeppelin & ClusterJongyoul Lee
 
Search and analyze your data with elasticsearch
Search and analyze your data with elasticsearchSearch and analyze your data with elasticsearch
Search and analyze your data with elasticsearchAnton Udovychenko
 
Hands-on Performance Tuning Lab - Devoxx Poland
Hands-on Performance Tuning Lab - Devoxx PolandHands-on Performance Tuning Lab - Devoxx Poland
Hands-on Performance Tuning Lab - Devoxx PolandC2B2 Consulting
 
Transactions in micro-services (fall 2019)
Transactions in micro-services (fall 2019)Transactions in micro-services (fall 2019)
Transactions in micro-services (fall 2019)Rudy De Busscher
 
Biomatters and Amazon Web Services
Biomatters and Amazon Web Services Biomatters and Amazon Web Services
Biomatters and Amazon Web Services Biomatters
 
Advanced queries on the Infinispan Data Grid
Advanced queries on the Infinispan Data Grid Advanced queries on the Infinispan Data Grid
Advanced queries on the Infinispan Data Grid C2B2 Consulting
 
Control and monitor_microservices_with_microprofile
Control and monitor_microservices_with_microprofileControl and monitor_microservices_with_microprofile
Control and monitor_microservices_with_microprofileRudy De Busscher
 
Deploying microservices on AWS
Deploying microservices on AWSDeploying microservices on AWS
Deploying microservices on AWSMichael Haberman
 
Zeppelin meetup 2016 madrid
Zeppelin meetup 2016 madridZeppelin meetup 2016 madrid
Zeppelin meetup 2016 madridJongyoul Lee
 

La actualidad más candente (20)

Display earthquakes with Akka-http
Display earthquakes with Akka-httpDisplay earthquakes with Akka-http
Display earthquakes with Akka-http
 
JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?
JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?
JDD 2016 - Jacek Bukowski - "Flying To Clouds" - Can It Be Easy?
 
Flying to clouds - can it be easy? Cloud Native Applications
Flying to clouds - can it be easy? Cloud Native ApplicationsFlying to clouds - can it be easy? Cloud Native Applications
Flying to clouds - can it be easy? Cloud Native Applications
 
Rainbows, Unicorns, and other Fairy Tales in the Land of Serverless Dreams
Rainbows, Unicorns, and other Fairy Tales in the Land of Serverless DreamsRainbows, Unicorns, and other Fairy Tales in the Land of Serverless Dreams
Rainbows, Unicorns, and other Fairy Tales in the Land of Serverless Dreams
 
Azkaban
AzkabanAzkaban
Azkaban
 
The 6 Rules for Modernizing Your Legacy Java Monolith with Microservices
The 6 Rules for Modernizing Your Legacy Java Monolith with MicroservicesThe 6 Rules for Modernizing Your Legacy Java Monolith with Microservices
The 6 Rules for Modernizing Your Legacy Java Monolith with Microservices
 
Getting ready to java 8
Getting ready to java 8Getting ready to java 8
Getting ready to java 8
 
Getting ready to java 8
Getting ready to java 8Getting ready to java 8
Getting ready to java 8
 
Training on iOS app development - Samesh Swongamikha & Neetin Sharma
Training on iOS app development - Samesh Swongamikha & Neetin SharmaTraining on iOS app development - Samesh Swongamikha & Neetin Sharma
Training on iOS app development - Samesh Swongamikha & Neetin Sharma
 
Apache Zeppelin & Cluster
Apache Zeppelin & ClusterApache Zeppelin & Cluster
Apache Zeppelin & Cluster
 
Search and analyze your data with elasticsearch
Search and analyze your data with elasticsearchSearch and analyze your data with elasticsearch
Search and analyze your data with elasticsearch
 
Hands-on Performance Tuning Lab - Devoxx Poland
Hands-on Performance Tuning Lab - Devoxx PolandHands-on Performance Tuning Lab - Devoxx Poland
Hands-on Performance Tuning Lab - Devoxx Poland
 
Uniqueness of java
Uniqueness of javaUniqueness of java
Uniqueness of java
 
Transactions in micro-services (fall 2019)
Transactions in micro-services (fall 2019)Transactions in micro-services (fall 2019)
Transactions in micro-services (fall 2019)
 
Biomatters and Amazon Web Services
Biomatters and Amazon Web Services Biomatters and Amazon Web Services
Biomatters and Amazon Web Services
 
Advanced queries on the Infinispan Data Grid
Advanced queries on the Infinispan Data Grid Advanced queries on the Infinispan Data Grid
Advanced queries on the Infinispan Data Grid
 
Remix
RemixRemix
Remix
 
Control and monitor_microservices_with_microprofile
Control and monitor_microservices_with_microprofileControl and monitor_microservices_with_microprofile
Control and monitor_microservices_with_microprofile
 
Deploying microservices on AWS
Deploying microservices on AWSDeploying microservices on AWS
Deploying microservices on AWS
 
Zeppelin meetup 2016 madrid
Zeppelin meetup 2016 madridZeppelin meetup 2016 madrid
Zeppelin meetup 2016 madrid
 

Destacado

Indic threads pune12-accelerating computation in html 5
Indic threads pune12-accelerating computation in html 5Indic threads pune12-accelerating computation in html 5
Indic threads pune12-accelerating computation in html 5IndicThreads
 
Phone for Me, Tablet for We: Building a multi screen app in One Hour
Phone for Me, Tablet for We: Building a multi screen app in One HourPhone for Me, Tablet for We: Building a multi screen app in One Hour
Phone for Me, Tablet for We: Building a multi screen app in One HourIndicThreads
 
Cloud development made easy with cloud foundry indicthreads cloud computing...
Cloud development made easy with cloud foundry   indicthreads cloud computing...Cloud development made easy with cloud foundry   indicthreads cloud computing...
Cloud development made easy with cloud foundry indicthreads cloud computing...IndicThreads
 
Indic threads pune12-recommenders-apache-mahout
Indic threads pune12-recommenders-apache-mahoutIndic threads pune12-recommenders-apache-mahout
Indic threads pune12-recommenders-apache-mahoutIndicThreads
 
Building modular applications
Building modular applicationsBuilding modular applications
Building modular applicationsIndicThreads
 
Http2 is here! And why the web needs it
Http2 is here! And why the web needs itHttp2 is here! And why the web needs it
Http2 is here! And why the web needs itIndicThreads
 

Destacado (9)

Moving to moodle 2
Moving to moodle 2Moving to moodle 2
Moving to moodle 2
 
Indic threads pune12-accelerating computation in html 5
Indic threads pune12-accelerating computation in html 5Indic threads pune12-accelerating computation in html 5
Indic threads pune12-accelerating computation in html 5
 
Phone for Me, Tablet for We: Building a multi screen app in One Hour
Phone for Me, Tablet for We: Building a multi screen app in One HourPhone for Me, Tablet for We: Building a multi screen app in One Hour
Phone for Me, Tablet for We: Building a multi screen app in One Hour
 
Cloud development made easy with cloud foundry indicthreads cloud computing...
Cloud development made easy with cloud foundry   indicthreads cloud computing...Cloud development made easy with cloud foundry   indicthreads cloud computing...
Cloud development made easy with cloud foundry indicthreads cloud computing...
 
The move to m2 colchsfc
The move to m2 colchsfcThe move to m2 colchsfc
The move to m2 colchsfc
 
Indic threads pune12-recommenders-apache-mahout
Indic threads pune12-recommenders-apache-mahoutIndic threads pune12-recommenders-apache-mahout
Indic threads pune12-recommenders-apache-mahout
 
Building modular applications
Building modular applicationsBuilding modular applications
Building modular applications
 
Rsc update feb 2014
Rsc update feb 2014Rsc update feb 2014
Rsc update feb 2014
 
Http2 is here! And why the web needs it
Http2 is here! And why the web needs itHttp2 is here! And why the web needs it
Http2 is here! And why the web needs it
 

Similar a Indic threads pune12-typesafe stack software development on the jvm

Typesafe stack - Scala, Akka and Play
Typesafe stack - Scala, Akka and PlayTypesafe stack - Scala, Akka and Play
Typesafe stack - Scala, Akka and PlayLuka Zakrajšek
 
Developing distributed applications with Akka and Akka Cluster
Developing distributed applications with Akka and Akka ClusterDeveloping distributed applications with Akka and Akka Cluster
Developing distributed applications with Akka and Akka ClusterKonstantin Tsykulenko
 
Building large scale, job processing systems with Scala Akka Actor framework
Building large scale, job processing systems with Scala Akka Actor frameworkBuilding large scale, job processing systems with Scala Akka Actor framework
Building large scale, job processing systems with Scala Akka Actor frameworkVignesh Sukumar
 
Composable Futures with Akka 2.0
Composable Futures with Akka 2.0Composable Futures with Akka 2.0
Composable Futures with Akka 2.0Mike Slinn
 
Agile Lab_BigData_Meetup_AKKA
Agile Lab_BigData_Meetup_AKKAAgile Lab_BigData_Meetup_AKKA
Agile Lab_BigData_Meetup_AKKAPaolo Platter
 
Real world Scala hAkking NLJUG JFall 2011
Real world Scala hAkking NLJUG JFall 2011Real world Scala hAkking NLJUG JFall 2011
Real world Scala hAkking NLJUG JFall 2011Raymond Roestenburg
 
Streaming Analytics with Spark, Kafka, Cassandra and Akka
Streaming Analytics with Spark, Kafka, Cassandra and AkkaStreaming Analytics with Spark, Kafka, Cassandra and Akka
Streaming Analytics with Spark, Kafka, Cassandra and AkkaHelena Edelson
 
Process Orchestration with Flowable and Spring Boot
Process Orchestration with Flowable and Spring BootProcess Orchestration with Flowable and Spring Boot
Process Orchestration with Flowable and Spring BootChavdar Baikov
 
Stay productive_while_slicing_up_the_monolith
Stay productive_while_slicing_up_the_monolithStay productive_while_slicing_up_the_monolith
Stay productive_while_slicing_up_the_monolithMarkus Eisele
 
DEVNET-1106 Upcoming Services in OpenStack
DEVNET-1106	Upcoming Services in OpenStackDEVNET-1106	Upcoming Services in OpenStack
DEVNET-1106 Upcoming Services in OpenStackCisco DevNet
 
Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and ActivatorKevin Webber
 
NDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design PatternsNDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design PatternsRyan Green
 
Concurrency in java
Concurrency in javaConcurrency in java
Concurrency in javaAbhra Basak
 
Architectures, Frameworks and Infrastructure
Architectures, Frameworks and InfrastructureArchitectures, Frameworks and Infrastructure
Architectures, Frameworks and Infrastructureharendra_pathak
 

Similar a Indic threads pune12-typesafe stack software development on the jvm (20)

Typesafe stack - Scala, Akka and Play
Typesafe stack - Scala, Akka and PlayTypesafe stack - Scala, Akka and Play
Typesafe stack - Scala, Akka and Play
 
Developing distributed applications with Akka and Akka Cluster
Developing distributed applications with Akka and Akka ClusterDeveloping distributed applications with Akka and Akka Cluster
Developing distributed applications with Akka and Akka Cluster
 
Building large scale, job processing systems with Scala Akka Actor framework
Building large scale, job processing systems with Scala Akka Actor frameworkBuilding large scale, job processing systems with Scala Akka Actor framework
Building large scale, job processing systems with Scala Akka Actor framework
 
Composable Futures with Akka 2.0
Composable Futures with Akka 2.0Composable Futures with Akka 2.0
Composable Futures with Akka 2.0
 
Agile Lab_BigData_Meetup_AKKA
Agile Lab_BigData_Meetup_AKKAAgile Lab_BigData_Meetup_AKKA
Agile Lab_BigData_Meetup_AKKA
 
Road Trip To Component
Road Trip To ComponentRoad Trip To Component
Road Trip To Component
 
Akka.Net Overview
Akka.Net OverviewAkka.Net Overview
Akka.Net Overview
 
Real world Scala hAkking NLJUG JFall 2011
Real world Scala hAkking NLJUG JFall 2011Real world Scala hAkking NLJUG JFall 2011
Real world Scala hAkking NLJUG JFall 2011
 
Streaming Analytics with Spark, Kafka, Cassandra and Akka
Streaming Analytics with Spark, Kafka, Cassandra and AkkaStreaming Analytics with Spark, Kafka, Cassandra and Akka
Streaming Analytics with Spark, Kafka, Cassandra and Akka
 
Process Orchestration with Flowable and Spring Boot
Process Orchestration with Flowable and Spring BootProcess Orchestration with Flowable and Spring Boot
Process Orchestration with Flowable and Spring Boot
 
Micro services Architecture
Micro services ArchitectureMicro services Architecture
Micro services Architecture
 
Stay productive_while_slicing_up_the_monolith
Stay productive_while_slicing_up_the_monolithStay productive_while_slicing_up_the_monolith
Stay productive_while_slicing_up_the_monolith
 
DEVNET-1106 Upcoming Services in OpenStack
DEVNET-1106	Upcoming Services in OpenStackDEVNET-1106	Upcoming Services in OpenStack
DEVNET-1106 Upcoming Services in OpenStack
 
Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and Activator
 
NDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design PatternsNDev Talk - Serverless Design Patterns
NDev Talk - Serverless Design Patterns
 
Fault tolerance
Fault toleranceFault tolerance
Fault tolerance
 
Concurrency in java
Concurrency in javaConcurrency in java
Concurrency in java
 
Azure basics
Azure basicsAzure basics
Azure basics
 
Architectures, Frameworks and Infrastructure
Architectures, Frameworks and InfrastructureArchitectures, Frameworks and Infrastructure
Architectures, Frameworks and Infrastructure
 
ZooKeeper (and other things)
ZooKeeper (and other things)ZooKeeper (and other things)
ZooKeeper (and other things)
 

Más de IndicThreads

Understanding Bitcoin (Blockchain) and its Potential for Disruptive Applications
Understanding Bitcoin (Blockchain) and its Potential for Disruptive ApplicationsUnderstanding Bitcoin (Blockchain) and its Potential for Disruptive Applications
Understanding Bitcoin (Blockchain) and its Potential for Disruptive ApplicationsIndicThreads
 
Go Programming Language - Learning The Go Lang way
Go Programming Language - Learning The Go Lang wayGo Programming Language - Learning The Go Lang way
Go Programming Language - Learning The Go Lang wayIndicThreads
 
Building Resilient Microservices
Building Resilient Microservices Building Resilient Microservices
Building Resilient Microservices IndicThreads
 
App using golang indicthreads
App using golang  indicthreadsApp using golang  indicthreads
App using golang indicthreadsIndicThreads
 
Building on quicksand microservices indicthreads
Building on quicksand microservices  indicthreadsBuilding on quicksand microservices  indicthreads
Building on quicksand microservices indicthreadsIndicThreads
 
How to Think in RxJava Before Reacting
How to Think in RxJava Before ReactingHow to Think in RxJava Before Reacting
How to Think in RxJava Before ReactingIndicThreads
 
Iot secure connected devices indicthreads
Iot secure connected devices indicthreadsIot secure connected devices indicthreads
Iot secure connected devices indicthreadsIndicThreads
 
Real world IoT for enterprises
Real world IoT for enterprisesReal world IoT for enterprises
Real world IoT for enterprisesIndicThreads
 
IoT testing and quality assurance indicthreads
IoT testing and quality assurance indicthreadsIoT testing and quality assurance indicthreads
IoT testing and quality assurance indicthreadsIndicThreads
 
Functional Programming Past Present Future
Functional Programming Past Present FutureFunctional Programming Past Present Future
Functional Programming Past Present FutureIndicThreads
 
Harnessing the Power of Java 8 Streams
Harnessing the Power of Java 8 Streams Harnessing the Power of Java 8 Streams
Harnessing the Power of Java 8 Streams IndicThreads
 
Building & scaling a live streaming mobile platform - Gr8 road to fame
Building & scaling a live streaming mobile platform - Gr8 road to fameBuilding & scaling a live streaming mobile platform - Gr8 road to fame
Building & scaling a live streaming mobile platform - Gr8 road to fameIndicThreads
 
Internet of things architecture perspective - IndicThreads Conference
Internet of things architecture perspective - IndicThreads ConferenceInternet of things architecture perspective - IndicThreads Conference
Internet of things architecture perspective - IndicThreads ConferenceIndicThreads
 
Cars and Computers: Building a Java Carputer
 Cars and Computers: Building a Java Carputer Cars and Computers: Building a Java Carputer
Cars and Computers: Building a Java CarputerIndicThreads
 
Scrap Your MapReduce - Apache Spark
 Scrap Your MapReduce - Apache Spark Scrap Your MapReduce - Apache Spark
Scrap Your MapReduce - Apache SparkIndicThreads
 
Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker
 Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker
Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & DockerIndicThreads
 
Speed up your build pipeline for faster feedback
Speed up your build pipeline for faster feedbackSpeed up your build pipeline for faster feedback
Speed up your build pipeline for faster feedbackIndicThreads
 
Unraveling OpenStack Clouds
 Unraveling OpenStack Clouds Unraveling OpenStack Clouds
Unraveling OpenStack CloudsIndicThreads
 
Digital Transformation of the Enterprise. What IT leaders need to know!
Digital Transformation of the Enterprise. What IT  leaders need to know!Digital Transformation of the Enterprise. What IT  leaders need to know!
Digital Transformation of the Enterprise. What IT leaders need to know!IndicThreads
 
Architectural Considerations For Complex Mobile And Web Applications
 Architectural Considerations For Complex Mobile And Web Applications Architectural Considerations For Complex Mobile And Web Applications
Architectural Considerations For Complex Mobile And Web ApplicationsIndicThreads
 

Más de IndicThreads (20)

Understanding Bitcoin (Blockchain) and its Potential for Disruptive Applications
Understanding Bitcoin (Blockchain) and its Potential for Disruptive ApplicationsUnderstanding Bitcoin (Blockchain) and its Potential for Disruptive Applications
Understanding Bitcoin (Blockchain) and its Potential for Disruptive Applications
 
Go Programming Language - Learning The Go Lang way
Go Programming Language - Learning The Go Lang wayGo Programming Language - Learning The Go Lang way
Go Programming Language - Learning The Go Lang way
 
Building Resilient Microservices
Building Resilient Microservices Building Resilient Microservices
Building Resilient Microservices
 
App using golang indicthreads
App using golang  indicthreadsApp using golang  indicthreads
App using golang indicthreads
 
Building on quicksand microservices indicthreads
Building on quicksand microservices  indicthreadsBuilding on quicksand microservices  indicthreads
Building on quicksand microservices indicthreads
 
How to Think in RxJava Before Reacting
How to Think in RxJava Before ReactingHow to Think in RxJava Before Reacting
How to Think in RxJava Before Reacting
 
Iot secure connected devices indicthreads
Iot secure connected devices indicthreadsIot secure connected devices indicthreads
Iot secure connected devices indicthreads
 
Real world IoT for enterprises
Real world IoT for enterprisesReal world IoT for enterprises
Real world IoT for enterprises
 
IoT testing and quality assurance indicthreads
IoT testing and quality assurance indicthreadsIoT testing and quality assurance indicthreads
IoT testing and quality assurance indicthreads
 
Functional Programming Past Present Future
Functional Programming Past Present FutureFunctional Programming Past Present Future
Functional Programming Past Present Future
 
Harnessing the Power of Java 8 Streams
Harnessing the Power of Java 8 Streams Harnessing the Power of Java 8 Streams
Harnessing the Power of Java 8 Streams
 
Building & scaling a live streaming mobile platform - Gr8 road to fame
Building & scaling a live streaming mobile platform - Gr8 road to fameBuilding & scaling a live streaming mobile platform - Gr8 road to fame
Building & scaling a live streaming mobile platform - Gr8 road to fame
 
Internet of things architecture perspective - IndicThreads Conference
Internet of things architecture perspective - IndicThreads ConferenceInternet of things architecture perspective - IndicThreads Conference
Internet of things architecture perspective - IndicThreads Conference
 
Cars and Computers: Building a Java Carputer
 Cars and Computers: Building a Java Carputer Cars and Computers: Building a Java Carputer
Cars and Computers: Building a Java Carputer
 
Scrap Your MapReduce - Apache Spark
 Scrap Your MapReduce - Apache Spark Scrap Your MapReduce - Apache Spark
Scrap Your MapReduce - Apache Spark
 
Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker
 Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker
Continuous Integration (CI) and Continuous Delivery (CD) using Jenkins & Docker
 
Speed up your build pipeline for faster feedback
Speed up your build pipeline for faster feedbackSpeed up your build pipeline for faster feedback
Speed up your build pipeline for faster feedback
 
Unraveling OpenStack Clouds
 Unraveling OpenStack Clouds Unraveling OpenStack Clouds
Unraveling OpenStack Clouds
 
Digital Transformation of the Enterprise. What IT leaders need to know!
Digital Transformation of the Enterprise. What IT  leaders need to know!Digital Transformation of the Enterprise. What IT  leaders need to know!
Digital Transformation of the Enterprise. What IT leaders need to know!
 
Architectural Considerations For Complex Mobile And Web Applications
 Architectural Considerations For Complex Mobile And Web Applications Architectural Considerations For Complex Mobile And Web Applications
Architectural Considerations For Complex Mobile And Web Applications
 

Indic threads pune12-typesafe stack software development on the jvm

  • 1. Typesafe Stack Software Development On The JVM Sushanta Pradhan Talentica Software (I) Pvt. Ltd.
  • 2. History of Hardware Architecture • Single core era • moore's law achieved by increasing clock cycles • Multi core era • moore's law achieved by increasing # of cores
  • 4. PPP – Grand Challenge • Parallel programming as easy as sequential programming • Moores’s law of performance – speed up 2 times year on year • Eliminate concurrency bugs
  • 5. History of software applications • pre .com era • standalone desktop apps • .com era • web sites - static web pages, automated business processes • data controlled by software vendor • deployed on data centers
  • 6. contd .. • web2.0/semantic web era • web/networked applications • Smart apps • data not controlled by vendor but by the users • deployed on cloud
  • 7. Properties of modern day App • Scalability • Distributed • Parallel & Concurrent • Dynamic • Agile & Swift
  • 8. Parallelism & Concurrency • Parallel Programming • parallel execution of programs • can't be performed without parallel hardware • programs get faster
  • 9. Parallelism & Concurrency • Concurrent Programming • simultaneous execution of programs • can be performed without parallel hardware • programs get more responsive Both are too hard !!
  • 10. Why Hard? • non-determinism due to shared mutable state by concurrent threads • encapsulate state in actors or transactors but fundamental problems still remains non-determinism = parallel processing + mutable state
  • 11. Remedy? PREVENTION IS BETTER THAN CURE !! • Avoid mutable state and get deterministic processing • Which means program functionally
  • 12. Space vs Time Space(functional/parallel) Time(imperative/concurrent)
  • 13. Scala • Hybrid – functional & object oriented (pure) • strong static typing • Agile - concise & expressive • Parallel & Sequential • intermixes well with Java
  • 14. Scala contd .. Parallellism • parallel collections • distributed collections Concurrency • Actors • STM Akka • Futures
  • 15. Scala contd .. • Concise Java • Immutability Val & Var • Tuples & Multiple Assignments • Sensible Defaults • Operator Overloading
  • 16. Scala classes .. • Terse • Object keyword - Singleton • Companion Objects • Type inference • Option[T] – Some[T], None
  • 18. Scala – Functional Aspects • Functions too are objects • Higher Order Functions • Partially applied Functions • Closures
  • 19. Scala Inehritance • Traits • Mixins • Type inference - implicit keyword
  • 20. Scala collections • Mutable & immutable • filter() • Map() • foldLeft() • foldRight()
  • 21. Scala – Pattern Matching • Advanced switch case • Literals and constants • WildCards • Tuples & Lists • Guards • Regular Expressions
  • 22. Scala - Concurrency • actor() • Actor Class • receive() & recieveWithin() • react() & reachWithin() • loop() & loopwhile()
  • 23. Akka - Middleware • Concurrent, Scalable & fault-tolerant • based on actor model • highly performant • event driven • location transparency
  • 24. Actor system • ensemble of actors sharing common configuration • hierarchical structure • heavyweight • has its own pool of resources threads
  • 25. Supervision • dependency relationship between actors • supervisor - subordinate model • supervisor monitors and reacts to any errors reported by subordinates • configurable supervision strategy • lifecycle monitoring
  • 26. Supervision hierarchy ”root guardian” ”guardian” shutdown “system guardian” order
  • 27. Remoting • ActorPath • purely local - "akka://my-sys/user/service-a/worker1" • local or remote - "akka://my-sys@host.example.com:5678 /user/service-b" • Seamlessly send messages to actors on remote nodes
  • 28. Routing • route messages to actors(routees) • ideal for load balancing • Examples • RoundRobinRouter • RandomRouter • SmallestMailboxRouter • BroadcastRouter
  • 29. Dispatchers • make akka actors tick • manages the resources(threads) used by actors • configure mailboxes of actors • Examples • fork-join-executor • thread-pool-executor
  • 30. Play • ruby on rails like agility • convention over configuration • seamless integration with akka for scalability • edit and test
  • 31. Play contd .. • an easy, out-of-the-box setup for unit and functional testing • asynchronous HTTP request handling • WebSocket support • cache support (e.g. memcached) • integrated JSON and XML handling
  • 32. Progressive Stream Processing • Iteratees • Enumerators • Enumeratees
  • 33. Q/A