SlideShare une entreprise Scribd logo
1  sur  34
Télécharger pour lire hors ligne
Gridify
your Spring application
    with Grid Gain
           Sergio Bossa
      Pro-Netics / Sourcesense
About me
✔   Software architect and engineer
    ➔   Pro-Netics (http://www.pronetics.it)
    ➔   Sourcesense (http://www.sourcesense.com)
✔   Blogger
    ➔   http://sbtourist.blogspot.com
✔   Open Source Enthusiast
    ➔   Lead at Scarlet - Clustering for Jira (http://scarlet.sf.net)
    ➔   Committer at Spring Modules
        (http://springmodules.dev.java.net)
    ➔   Committer at Taconite Ajax Framework
        (http://taconite.sourceforge.net/)
Agenda
✔   Common ground.
    ➔   Why Grid?
    ➔   Performance and Scalability.
    ➔   Map / Reduce.
✔   Grid Gain and The Spring Framework.
    ➔   Grid Gain concepts.
    ➔   Grid Gain on Spring.
    ➔   A practical example.
Why grid?
                     Social changes
✔   Cheaper hardware.
    ➔   Computer as an off-the-shelf product.
✔   Web explosion.
    ➔   Everything is on the web.
    ➔   Everyone is on the web.
        ➔   More and more users.
        ➔   More and more transactions.
Why grid?
               Technological changes
✔   Cheaper hardware.
    ➔   We have more power.
        ➔   We want more speed.
✔   Moore's Law: the number of transistors that can be
    inexpensively placed on an integrated circuit is
    increasing exponentially.
    ➔   But we had to go from single-core processors to multi-
        core ones ...
    ➔   So your for-loop will always run at the same speed.
        ➔   Forever.
Why grid?


   +

   =
Performance
It's all about doing one thing.
             Faster.
Scalability
It's all about doing the same one thing.
             In a bigger way.
Performance vs Scalability

✔   Performance is about how fast.
✔   Scalability is about how much.
✔   Nowadays, if you want to save your job and hears
    (remember that Boss screaming at your face) ...
    ➔   You have to scale.
Scalability in two words
✔   Vertical scalability is about adding more and more
    power (CPU, RAM ...) to your single computer.
    ➔   Also known as scaling-in.
    ➔   Finite and costly.
✔   Horizontal scalability is about adding more and more
    computers.
    ➔   Also known as scaling-out.
    ➔   Infinite and cheaper, because using commodity
        hardware.
✔   Guess what, we want to scale-out ...
The scalability factor

✔   Available resources while scaling out.
    ➔   Linear scalability.
    ➔   Supra-linear scalability.
    ➔   Sub-linear scalability.
    ➔   Negative scalability.
✔   A scalable application should always strive for (almost)
    linear scalability.
The scalability problem


✔   Amdahl's Law: performance decreases as number of
    processors increases once there is even a small
    percentage of non-parallelizable code.
    ➔   Most of the software is written in a non-parallelizable
        way.
    ➔   Writing software that scales out is perceived as hard.
Entering Map / Reduce

✔   From Google Labs.
    ➔   Is it enough?
Map / Reduce explained
✔   Programming model for linearly scaling out.
✔   De-facto standard for parallelizing intensive processing
    tasks.
✔   Based on:
    ➔   Splitting tasks into several parallelizable jobs grouped
        by key.
    ➔   Mapping jobs to processing units, optionally taking
        into account the job key.
    ➔   Merging jobs results, joining them into a global task
        result.
Map / Reduce illustrated
   Counting words
Grid computing with Map / Reduce

✔   Grid computing.
    ➔   Basically, a way to exploit multi-core / multi-
        processors / multi-computer environments for
        achieving horizontal scalability.
✔   Map / Reduce.
    ➔   Common paradigm in grid computing for
        implementing scalable applications.
Entering Grid Gain
✔   Open Source Grid Computing Framework.
    ➔   Web : http://www.gridgain.com
    ➔   Created and supported by Grid Gain Systems.
        ➔   Community support.
        ➔   Professional support.
✔   Powerful, yet simple, yet fun, Map / Reduce
    implementation.
✔   Integrated with major servlet containers and application
    servers.
✔   Integrated with major data grid solutions.
✔   Integrated with the Spring Framework.
Map / Reduce in Grid Gain

               -1-
               Task arrives to the first grid node, where is
               split into three jobs.
               First job is self-assigned and processed.
               -2-
               Second job is sent to the second grid node,
               where is processed.
               -3-
               Third job is sent to a the third grid node,
               where is processed.
               -4-
               Result from the second job is collected by
               the task on the first node.
               -5-
               Result from the third job is collected by the
               task on the first node.
               -6-
               Collected job results, together with the
               result from the first job, are reduced by the
               task and returned as a global result.
Grid Gain Quick Start
✔   GridTask.
    ➔   Implements the Map / Reduce logic.
✔   GridJob.
    ➔   Implements the processing logic.
✔   GridFactory.
    ➔   Provides access to the grid for executing tasks.
✔   Automatic deployment.
    ➔   Tasks are automatically deployed to the grid.
✔   Peer class loading.
    ➔   Needed classes are automatically loaded from peers.
Grid Gain Advanced
✔   SPI (Service Provider Interface) based configuration.
    ➔   Discovery SPI.
    ➔   Topology SPI.
    ➔   Checkpoint SPI.
    ➔   Load Balancing SPI.
    ➔   Collision SPI.
    ➔   Failover SPI.
    ➔   Metrics SPI.
    ➔   ...
Entering Spring Framework

The leading full-stack Java/JEE application framework.
Grid Gain on Spring


✔   POJO configuration.
✔   AOP grid execution.
✔   Resource Look-up.
Spring-based configuration
✔   POJO-based.
✔   Spring-based.
✔   GridConfiguration
    ➔   Configure grid parameters.
    ➔   Configure actual SPI implementations.
    ➔   Declared as a Spring bean.
✔   GridFactory
    ➔   GridFactory.start(GridConfiguration cfg)
    ➔   GridFactory.start(String springCfg)
AOP-based grid execution
✔   Parallelization on grid as a cross-cutting concern.
✔   Transparent task deployment and execution.
✔   Gridify
    ➔   Annotation to identify methods that must be executed
        on grid.
✔   GridifySpringEnhancer
    ➔   Proxy-based enhancer for executing annotated object
        methods on grid as an aspect.
Container-based resource look-
                 up.
✔   Spring application context as a source for resources
    needed by tasks and jobs.
✔   GridSpringApplicationContextResource
    ➔   Annotation for injecting the Spring application context
        into tasks and jobs.
✔   GridFactory.start(GridConfiguration cfg,
    ApplicationContext springCtx)
    ➔   Starts grid with a specific context to use for looking-up
        resources.
An Example
The Business Problem
An Example
The Grid Task
An Example
The Grid Job
An Example
Grid Configuration
An Example
Grid Starter
An Example
Grid Tester (...)
An Example
Grid Tester (... continued)
Q&A
Thank you
       Sergio Bossa
   s.bossa@pronetics.it
s.bossa@sourcesense.com

Contenu connexe

Tendances

Collecting metrics with Graphite and StatsD
Collecting metrics with Graphite and StatsDCollecting metrics with Graphite and StatsD
Collecting metrics with Graphite and StatsDitnig
 
Google Cloud Dataflow meets TensorFlow
Google Cloud Dataflow meets TensorFlowGoogle Cloud Dataflow meets TensorFlow
Google Cloud Dataflow meets TensorFlowHayato Yoshikawa
 
Resource Scheduling using Apache Mesos in Cloud Native Environments
Resource Scheduling using Apache Mesos in Cloud Native EnvironmentsResource Scheduling using Apache Mesos in Cloud Native Environments
Resource Scheduling using Apache Mesos in Cloud Native EnvironmentsSharma Podila
 
GCPUG.TW - GCP學習資源分享
GCPUG.TW - GCP學習資源分享GCPUG.TW - GCP學習資源分享
GCPUG.TW - GCP學習資源分享Simon Su
 
Scaling Graphite At Yelp
Scaling Graphite At YelpScaling Graphite At Yelp
Scaling Graphite At YelpPaul O'Connor
 
Building Robust Pipelines with Airflow
Building Robust Pipelines with AirflowBuilding Robust Pipelines with Airflow
Building Robust Pipelines with AirflowErin Shellman
 
Apache Beam and Google Cloud Dataflow - IDG - final
Apache Beam and Google Cloud Dataflow - IDG - finalApache Beam and Google Cloud Dataflow - IDG - final
Apache Beam and Google Cloud Dataflow - IDG - finalSub Szabolcs Feczak
 
Using A100 MIG to Scale Astronomy Scientific Output
Using A100 MIG to Scale Astronomy Scientific OutputUsing A100 MIG to Scale Astronomy Scientific Output
Using A100 MIG to Scale Astronomy Scientific OutputIgor Sfiligoi
 
Intro to Airflow: Goodbye Cron, Welcome scheduled workflow management
Intro to Airflow: Goodbye Cron, Welcome scheduled workflow managementIntro to Airflow: Goodbye Cron, Welcome scheduled workflow management
Intro to Airflow: Goodbye Cron, Welcome scheduled workflow managementBurasakorn Sabyeying
 
The Future starts with a Promise
The Future starts with a PromiseThe Future starts with a Promise
The Future starts with a PromiseAlexandru Nedelcu
 
Cloud native java script apps
Cloud native java script appsCloud native java script apps
Cloud native java script appsGary Sieling
 
BlazingSQL & Graphistry - Netflow Demo
BlazingSQL & Graphistry - Netflow DemoBlazingSQL & Graphistry - Netflow Demo
BlazingSQL & Graphistry - Netflow DemoRodrigo Aramburu
 
Hadoop & Spark Performance tuning using Dr. Elephant
Hadoop & Spark Performance tuning using Dr. ElephantHadoop & Spark Performance tuning using Dr. Elephant
Hadoop & Spark Performance tuning using Dr. ElephantAkshay Rai
 
Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...
Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...
Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...Joseph Luchette
 
AWS re:Invent 2014 talk: Scheduling using Apache Mesos in the Cloud
AWS re:Invent 2014 talk: Scheduling using Apache Mesos in the CloudAWS re:Invent 2014 talk: Scheduling using Apache Mesos in the Cloud
AWS re:Invent 2014 talk: Scheduling using Apache Mesos in the CloudSharma Podila
 
Airflow Clustering and High Availability
Airflow Clustering and High AvailabilityAirflow Clustering and High Availability
Airflow Clustering and High AvailabilityRobert Sanders
 
Device status anomaly detection
Device status anomaly detectionDevice status anomaly detection
Device status anomaly detectionDavid Tung
 
Graphs as Streams: Rethinking Graph Processing in the Streaming Era
Graphs as Streams: Rethinking Graph Processing in the Streaming EraGraphs as Streams: Rethinking Graph Processing in the Streaming Era
Graphs as Streams: Rethinking Graph Processing in the Streaming EraVasia Kalavri
 

Tendances (20)

Collecting metrics with Graphite and StatsD
Collecting metrics with Graphite and StatsDCollecting metrics with Graphite and StatsD
Collecting metrics with Graphite and StatsD
 
Google Cloud Dataflow meets TensorFlow
Google Cloud Dataflow meets TensorFlowGoogle Cloud Dataflow meets TensorFlow
Google Cloud Dataflow meets TensorFlow
 
Resource Scheduling using Apache Mesos in Cloud Native Environments
Resource Scheduling using Apache Mesos in Cloud Native EnvironmentsResource Scheduling using Apache Mesos in Cloud Native Environments
Resource Scheduling using Apache Mesos in Cloud Native Environments
 
GCPUG.TW - GCP學習資源分享
GCPUG.TW - GCP學習資源分享GCPUG.TW - GCP學習資源分享
GCPUG.TW - GCP學習資源分享
 
Scaling Graphite At Yelp
Scaling Graphite At YelpScaling Graphite At Yelp
Scaling Graphite At Yelp
 
Building Robust Pipelines with Airflow
Building Robust Pipelines with AirflowBuilding Robust Pipelines with Airflow
Building Robust Pipelines with Airflow
 
Apache Beam and Google Cloud Dataflow - IDG - final
Apache Beam and Google Cloud Dataflow - IDG - finalApache Beam and Google Cloud Dataflow - IDG - final
Apache Beam and Google Cloud Dataflow - IDG - final
 
Using A100 MIG to Scale Astronomy Scientific Output
Using A100 MIG to Scale Astronomy Scientific OutputUsing A100 MIG to Scale Astronomy Scientific Output
Using A100 MIG to Scale Astronomy Scientific Output
 
Intro to Airflow: Goodbye Cron, Welcome scheduled workflow management
Intro to Airflow: Goodbye Cron, Welcome scheduled workflow managementIntro to Airflow: Goodbye Cron, Welcome scheduled workflow management
Intro to Airflow: Goodbye Cron, Welcome scheduled workflow management
 
The Future starts with a Promise
The Future starts with a PromiseThe Future starts with a Promise
The Future starts with a Promise
 
Cloud native java script apps
Cloud native java script appsCloud native java script apps
Cloud native java script apps
 
Airflow at WePay
Airflow at WePayAirflow at WePay
Airflow at WePay
 
BlazingSQL & Graphistry - Netflow Demo
BlazingSQL & Graphistry - Netflow DemoBlazingSQL & Graphistry - Netflow Demo
BlazingSQL & Graphistry - Netflow Demo
 
Hadoop & Spark Performance tuning using Dr. Elephant
Hadoop & Spark Performance tuning using Dr. ElephantHadoop & Spark Performance tuning using Dr. Elephant
Hadoop & Spark Performance tuning using Dr. Elephant
 
Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...
Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...
Unlimited Virtual Computing Capacity using the Cloud for Automated Parameter ...
 
AWS re:Invent 2014 talk: Scheduling using Apache Mesos in the Cloud
AWS re:Invent 2014 talk: Scheduling using Apache Mesos in the CloudAWS re:Invent 2014 talk: Scheduling using Apache Mesos in the Cloud
AWS re:Invent 2014 talk: Scheduling using Apache Mesos in the Cloud
 
Airflow Clustering and High Availability
Airflow Clustering and High AvailabilityAirflow Clustering and High Availability
Airflow Clustering and High Availability
 
Device status anomaly detection
Device status anomaly detectionDevice status anomaly detection
Device status anomaly detection
 
Graphs as Streams: Rethinking Graph Processing in the Streaming Era
Graphs as Streams: Rethinking Graph Processing in the Streaming EraGraphs as Streams: Rethinking Graph Processing in the Streaming Era
Graphs as Streams: Rethinking Graph Processing in the Streaming Era
 
Graphite
GraphiteGraphite
Graphite
 

Similaire à Gridify your Spring application with Grid Gain @ Spring Italian Meeting 2008

Lightweight Grids With Terracotta
Lightweight Grids With TerracottaLightweight Grids With Terracotta
Lightweight Grids With TerracottaPT.JUG
 
DOSUG GridGain Java Grid Computing Made Simple
DOSUG GridGain Java Grid Computing Made SimpleDOSUG GridGain Java Grid Computing Made Simple
DOSUG GridGain Java Grid Computing Made SimpleMatthew McCullough
 
GridGain - Java Grid Computing Made Simple
GridGain - Java Grid Computing Made SimpleGridGain - Java Grid Computing Made Simple
GridGain - Java Grid Computing Made SimpleMatthew McCullough
 
Castles in the Cloud: Developing with Google App Engine
Castles in the Cloud: Developing with Google App EngineCastles in the Cloud: Developing with Google App Engine
Castles in the Cloud: Developing with Google App Enginecatherinewall
 
Deep Learning on AWS (November 2016)
Deep Learning on AWS (November 2016)Deep Learning on AWS (November 2016)
Deep Learning on AWS (November 2016)Julien SIMON
 
Rails Conf Europe 2007 Notes
Rails Conf  Europe 2007  NotesRails Conf  Europe 2007  Notes
Rails Conf Europe 2007 NotesRoss Lawley
 
[Roblek] Distributed computing in practice
[Roblek] Distributed computing in practice[Roblek] Distributed computing in practice
[Roblek] Distributed computing in practicejavablend
 
Empowering the AWS DynamoDB™ application developer with Alternator
Empowering the AWS DynamoDB™ application developer with AlternatorEmpowering the AWS DynamoDB™ application developer with Alternator
Empowering the AWS DynamoDB™ application developer with AlternatorScyllaDB
 
Profiling & Testing with Spark
Profiling & Testing with SparkProfiling & Testing with Spark
Profiling & Testing with SparkRoger Rafanell Mas
 
Galaxy
GalaxyGalaxy
Galaxybosc
 
Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...
Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...
Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...Nane Kratzke
 
Gatling - Stress test tool
Gatling - Stress test toolGatling - Stress test tool
Gatling - Stress test toolKnoldus Inc.
 
Ten practical ways to improve front-end performance
Ten practical ways to improve front-end performanceTen practical ways to improve front-end performance
Ten practical ways to improve front-end performanceAndrew Rota
 
Deep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech TalksDeep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech TalksAmazon Web Services
 
Deep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech TalksDeep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech TalksAmazon Web Services
 
10 things i wish i'd known before using spark in production
10 things i wish i'd known before using spark in production10 things i wish i'd known before using spark in production
10 things i wish i'd known before using spark in productionParis Data Engineers !
 
Spark: The State of the Art Engine for Big Data Processing
Spark: The State of the Art Engine for Big Data ProcessingSpark: The State of the Art Engine for Big Data Processing
Spark: The State of the Art Engine for Big Data ProcessingRamaninder Singh Jhajj
 
AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09Chris Purrington
 

Similaire à Gridify your Spring application with Grid Gain @ Spring Italian Meeting 2008 (20)

Lightweight Grids With Terracotta
Lightweight Grids With TerracottaLightweight Grids With Terracotta
Lightweight Grids With Terracotta
 
DOSUG GridGain Java Grid Computing Made Simple
DOSUG GridGain Java Grid Computing Made SimpleDOSUG GridGain Java Grid Computing Made Simple
DOSUG GridGain Java Grid Computing Made Simple
 
GridGain - Java Grid Computing Made Simple
GridGain - Java Grid Computing Made SimpleGridGain - Java Grid Computing Made Simple
GridGain - Java Grid Computing Made Simple
 
Castles in the Cloud: Developing with Google App Engine
Castles in the Cloud: Developing with Google App EngineCastles in the Cloud: Developing with Google App Engine
Castles in the Cloud: Developing with Google App Engine
 
Deep Learning on AWS (November 2016)
Deep Learning on AWS (November 2016)Deep Learning on AWS (November 2016)
Deep Learning on AWS (November 2016)
 
Rails Conf Europe 2007 Notes
Rails Conf  Europe 2007  NotesRails Conf  Europe 2007  Notes
Rails Conf Europe 2007 Notes
 
[Roblek] Distributed computing in practice
[Roblek] Distributed computing in practice[Roblek] Distributed computing in practice
[Roblek] Distributed computing in practice
 
Empowering the AWS DynamoDB™ application developer with Alternator
Empowering the AWS DynamoDB™ application developer with AlternatorEmpowering the AWS DynamoDB™ application developer with Alternator
Empowering the AWS DynamoDB™ application developer with Alternator
 
Profiling & Testing with Spark
Profiling & Testing with SparkProfiling & Testing with Spark
Profiling & Testing with Spark
 
Galaxy
GalaxyGalaxy
Galaxy
 
Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...
Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...
Smuggling Multi-Cloud Support into Cloud-native Applications using Elastic Co...
 
Gatling - Stress test tool
Gatling - Stress test toolGatling - Stress test tool
Gatling - Stress test tool
 
Gatling
GatlingGatling
Gatling
 
Ten practical ways to improve front-end performance
Ten practical ways to improve front-end performanceTen practical ways to improve front-end performance
Ten practical ways to improve front-end performance
 
Deep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech TalksDeep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive: Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
 
Deep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech TalksDeep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
Deep Dive on Amazon EC2 Elastic GPUs - May 2017 AWS Online Tech Talks
 
10 things i wish i'd known before using spark in production
10 things i wish i'd known before using spark in production10 things i wish i'd known before using spark in production
10 things i wish i'd known before using spark in production
 
Spark: The State of the Art Engine for Big Data Processing
Spark: The State of the Art Engine for Big Data ProcessingSpark: The State of the Art Engine for Big Data Processing
Spark: The State of the Art Engine for Big Data Processing
 
vega
vegavega
vega
 
AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09
 

Plus de Sergio Bossa

To be relational, or not to be relational? That's NOT the question!
To be relational, or not to be relational? That's NOT the question!To be relational, or not to be relational? That's NOT the question!
To be relational, or not to be relational? That's NOT the question!Sergio Bossa
 
Three Languages in Thirty Minutes
Three Languages in Thirty MinutesThree Languages in Thirty Minutes
Three Languages in Thirty MinutesSergio Bossa
 
Terrastore - A document database for developers
Terrastore - A document database for developersTerrastore - A document database for developers
Terrastore - A document database for developersSergio Bossa
 
Actor concurrency for the JVM: a case study
Actor concurrency for the JVM: a case studyActor concurrency for the JVM: a case study
Actor concurrency for the JVM: a case studySergio Bossa
 
Scalable Databases - From Relational Databases To Polyglot Persistence
Scalable Databases - From Relational Databases To Polyglot PersistenceScalable Databases - From Relational Databases To Polyglot Persistence
Scalable Databases - From Relational Databases To Polyglot PersistenceSergio Bossa
 
Scale Your Database And Be Happy
Scale Your Database And Be HappyScale Your Database And Be Happy
Scale Your Database And Be HappySergio Bossa
 
Clustering In The Wild
Clustering In The WildClustering In The Wild
Clustering In The WildSergio Bossa
 

Plus de Sergio Bossa (8)

To be relational, or not to be relational? That's NOT the question!
To be relational, or not to be relational? That's NOT the question!To be relational, or not to be relational? That's NOT the question!
To be relational, or not to be relational? That's NOT the question!
 
Three Languages in Thirty Minutes
Three Languages in Thirty MinutesThree Languages in Thirty Minutes
Three Languages in Thirty Minutes
 
Terrastore - A document database for developers
Terrastore - A document database for developersTerrastore - A document database for developers
Terrastore - A document database for developers
 
Actor concurrency for the JVM: a case study
Actor concurrency for the JVM: a case studyActor concurrency for the JVM: a case study
Actor concurrency for the JVM: a case study
 
Scalable Databases - From Relational Databases To Polyglot Persistence
Scalable Databases - From Relational Databases To Polyglot PersistenceScalable Databases - From Relational Databases To Polyglot Persistence
Scalable Databases - From Relational Databases To Polyglot Persistence
 
Scale Your Database And Be Happy
Scale Your Database And Be HappyScale Your Database And Be Happy
Scale Your Database And Be Happy
 
Clustering In The Wild
Clustering In The WildClustering In The Wild
Clustering In The Wild
 
Real Terracotta
Real TerracottaReal Terracotta
Real Terracotta
 

Dernier

TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 

Dernier (20)

TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 

Gridify your Spring application with Grid Gain @ Spring Italian Meeting 2008

  • 1. Gridify your Spring application with Grid Gain Sergio Bossa Pro-Netics / Sourcesense
  • 2. About me ✔ Software architect and engineer ➔ Pro-Netics (http://www.pronetics.it) ➔ Sourcesense (http://www.sourcesense.com) ✔ Blogger ➔ http://sbtourist.blogspot.com ✔ Open Source Enthusiast ➔ Lead at Scarlet - Clustering for Jira (http://scarlet.sf.net) ➔ Committer at Spring Modules (http://springmodules.dev.java.net) ➔ Committer at Taconite Ajax Framework (http://taconite.sourceforge.net/)
  • 3. Agenda ✔ Common ground. ➔ Why Grid? ➔ Performance and Scalability. ➔ Map / Reduce. ✔ Grid Gain and The Spring Framework. ➔ Grid Gain concepts. ➔ Grid Gain on Spring. ➔ A practical example.
  • 4. Why grid? Social changes ✔ Cheaper hardware. ➔ Computer as an off-the-shelf product. ✔ Web explosion. ➔ Everything is on the web. ➔ Everyone is on the web. ➔ More and more users. ➔ More and more transactions.
  • 5. Why grid? Technological changes ✔ Cheaper hardware. ➔ We have more power. ➔ We want more speed. ✔ Moore's Law: the number of transistors that can be inexpensively placed on an integrated circuit is increasing exponentially. ➔ But we had to go from single-core processors to multi- core ones ... ➔ So your for-loop will always run at the same speed. ➔ Forever.
  • 7. Performance It's all about doing one thing. Faster.
  • 8. Scalability It's all about doing the same one thing. In a bigger way.
  • 9. Performance vs Scalability ✔ Performance is about how fast. ✔ Scalability is about how much. ✔ Nowadays, if you want to save your job and hears (remember that Boss screaming at your face) ... ➔ You have to scale.
  • 10. Scalability in two words ✔ Vertical scalability is about adding more and more power (CPU, RAM ...) to your single computer. ➔ Also known as scaling-in. ➔ Finite and costly. ✔ Horizontal scalability is about adding more and more computers. ➔ Also known as scaling-out. ➔ Infinite and cheaper, because using commodity hardware. ✔ Guess what, we want to scale-out ...
  • 11. The scalability factor ✔ Available resources while scaling out. ➔ Linear scalability. ➔ Supra-linear scalability. ➔ Sub-linear scalability. ➔ Negative scalability. ✔ A scalable application should always strive for (almost) linear scalability.
  • 12. The scalability problem ✔ Amdahl's Law: performance decreases as number of processors increases once there is even a small percentage of non-parallelizable code. ➔ Most of the software is written in a non-parallelizable way. ➔ Writing software that scales out is perceived as hard.
  • 13. Entering Map / Reduce ✔ From Google Labs. ➔ Is it enough?
  • 14. Map / Reduce explained ✔ Programming model for linearly scaling out. ✔ De-facto standard for parallelizing intensive processing tasks. ✔ Based on: ➔ Splitting tasks into several parallelizable jobs grouped by key. ➔ Mapping jobs to processing units, optionally taking into account the job key. ➔ Merging jobs results, joining them into a global task result.
  • 15. Map / Reduce illustrated Counting words
  • 16. Grid computing with Map / Reduce ✔ Grid computing. ➔ Basically, a way to exploit multi-core / multi- processors / multi-computer environments for achieving horizontal scalability. ✔ Map / Reduce. ➔ Common paradigm in grid computing for implementing scalable applications.
  • 17. Entering Grid Gain ✔ Open Source Grid Computing Framework. ➔ Web : http://www.gridgain.com ➔ Created and supported by Grid Gain Systems. ➔ Community support. ➔ Professional support. ✔ Powerful, yet simple, yet fun, Map / Reduce implementation. ✔ Integrated with major servlet containers and application servers. ✔ Integrated with major data grid solutions. ✔ Integrated with the Spring Framework.
  • 18. Map / Reduce in Grid Gain -1- Task arrives to the first grid node, where is split into three jobs. First job is self-assigned and processed. -2- Second job is sent to the second grid node, where is processed. -3- Third job is sent to a the third grid node, where is processed. -4- Result from the second job is collected by the task on the first node. -5- Result from the third job is collected by the task on the first node. -6- Collected job results, together with the result from the first job, are reduced by the task and returned as a global result.
  • 19. Grid Gain Quick Start ✔ GridTask. ➔ Implements the Map / Reduce logic. ✔ GridJob. ➔ Implements the processing logic. ✔ GridFactory. ➔ Provides access to the grid for executing tasks. ✔ Automatic deployment. ➔ Tasks are automatically deployed to the grid. ✔ Peer class loading. ➔ Needed classes are automatically loaded from peers.
  • 20. Grid Gain Advanced ✔ SPI (Service Provider Interface) based configuration. ➔ Discovery SPI. ➔ Topology SPI. ➔ Checkpoint SPI. ➔ Load Balancing SPI. ➔ Collision SPI. ➔ Failover SPI. ➔ Metrics SPI. ➔ ...
  • 21. Entering Spring Framework The leading full-stack Java/JEE application framework.
  • 22. Grid Gain on Spring ✔ POJO configuration. ✔ AOP grid execution. ✔ Resource Look-up.
  • 23. Spring-based configuration ✔ POJO-based. ✔ Spring-based. ✔ GridConfiguration ➔ Configure grid parameters. ➔ Configure actual SPI implementations. ➔ Declared as a Spring bean. ✔ GridFactory ➔ GridFactory.start(GridConfiguration cfg) ➔ GridFactory.start(String springCfg)
  • 24. AOP-based grid execution ✔ Parallelization on grid as a cross-cutting concern. ✔ Transparent task deployment and execution. ✔ Gridify ➔ Annotation to identify methods that must be executed on grid. ✔ GridifySpringEnhancer ➔ Proxy-based enhancer for executing annotated object methods on grid as an aspect.
  • 25. Container-based resource look- up. ✔ Spring application context as a source for resources needed by tasks and jobs. ✔ GridSpringApplicationContextResource ➔ Annotation for injecting the Spring application context into tasks and jobs. ✔ GridFactory.start(GridConfiguration cfg, ApplicationContext springCtx) ➔ Starts grid with a specific context to use for looking-up resources.
  • 32. An Example Grid Tester (... continued)
  • 33. Q&A
  • 34. Thank you Sergio Bossa s.bossa@pronetics.it s.bossa@sourcesense.com