SlideShare uma empresa Scribd logo
1 de 33
Baixar para ler offline
Taking the next step shouldn’t be scary …




             Messaging for Modern Applications
                            CONFIDENTIAL         1
Messaging for Modern Applications

Pronam Chatterjee, Staff Systems Engineer, VMware
Email: pronamc@vmware.com
Twitter: pronamc




                                                                                  CONFIDENTIAL
                                                    © 2010 SpringSource, A division of VMware. All rights reserved
Session Agenda

• Modern Applications
   – Trends and Impact on Messaging
   – Impact on Application Architecture

• Spring Integration
   – Messaging Use Cases
   – Messaging DSL for Spring Applications

• AMQP
   – Why AMQP?
   – AMQP Architecture

• RabbitMQ
   – Why RabbitMQ?
   – RabbitMQ Architecture

                                CONFIDENTIAL   3
Modern Application Trends

• Written with frameworks
  – Developer productivity and innovation

• New Application Types
   – Mobile, SaaS, Social
   – Apps released early and often

• Data intensive
   – Emerging requirements: elasticity, multi-cloud
   – Web orientation drives exponential data
     volumes

• Deployed on virtual and cloud infrastructure
   – Trending toward hybrid (public and private)
     infrastructure
                                CONFIDENTIAL          4
Today’s Middleware and Databases Not Keeping Up


                      Rise of Modern Developer Frameworks


                            Service                 Loose
         Simplicity                                               Polyglot
                          Consumption              Coupling



                              Today’s
                      Middleware and Databases


           Service           Elastic             Elastic      Virtualization
           Delivery        Deployment            Scaling          Aware


                      Rise of Virtual and Cloud Infrastructure



                                  CONFIDENTIAL                                 5
Modern Applications need Modern Messaging

                                      Traditional approaches to messaging
                                       imply predictable, static interaction
                                         between well-known end-points




  Modern approaches to messaging
 embrace the unpredictable, dynamic,
   and transient nature of the web


                               CONFIDENTIAL                                6
Synchronous Architecture is Brittle


      An exception
        occurred,                                  Manage
      please resend                               Inventory
                      Place          Fulfill
                      Order          Order
                                                          X
                                                          X
           X           X                X
                       X                X
                                                          X
                                                          X
                                                  Schedule
                                                  Delivery




    If any component is unavailable within this synchronous flow, all
   in-flight messages will be affected, regardless of what component
     they are currently in -- and since state is maintained across the
             components, the system can be complex to reset


                                  CONFIDENTIAL                           7
Asynchronous Architecture Rules the Web
                          The status of
                          your order is            I can fulfill
                               …                      part of
                                                   that Order


         I have an
           Order

                                                                   I can fulfill
                                                                      part of
       Your order will                                             that Order
        be delivered
        next Tuesday



                             I’ll schedule
                              delivery of
                               that order

  In this asynchronous flow:
  • all state is kept in the simple messages being passed
  • each stateless component interacts only with the broker cloud
  • if a component is lost, only the in-flight messages within that
     component must be re-delivered
  • components can be quickly provisioned on-demand
                                    CONFIDENTIAL                                   8
How is Messaging Used within Modern Apps?

  Event
  I need to know when to do something
  Fragment
  I need to only give you a piece of this data
  Route
  Control who gets which message, without changing sender or receiver
  Batch
  Producer and consumer can run at independent times
  Publish
  Tell everyone who wants to know about this
  Modularity
  Deploy, Scale, and Version a distributed system


                                  CONFIDENTIAL                          9
Spring Integration




      CONFIDENTIAL   10
What is Spring Integration?



• At the core, an embedded Message Bus
   – Inspired by Gregor Hohpe and Bobby Woolf's Enterprise
     Integration Patterns (2004)
   – Runs within any Spring ApplicationContext
   – All components are Spring-managed objects

• Also, an Application Integration Framework
   – Connects to other systems via adapters
   – Unidirectional Channel Adapters
   – Bidirectional Messaging Gateways




                           CONFIDENTIAL                      11
Event

I need to know when to do something …
                <service-activator
                  input-channel="hotDrinks”
                  ref="barista"
                  method="prepareHotDrink"
                  output-channel="preparedDrinks” />




     An Event-Driven Consumer is one that is automatically handed
   messages as they’re delivered on the channel. The receiver acts like
  the message delivery is an event that triggers the receiver into action.

                                  CONFIDENTIAL                               12
Fragment

I need to only give you this piece of data …

               <int:splitter
                         input-channel="orders”
                         expression="payload.items”
                         output-channel="drinks” />




   Use a Splitter to break out the composite message into a series of
    individual messages, each containing data related to one item.

                                 CONFIDENTIAL                           13
Route

Control who gets what message

        <int:router
                 input-channel="drinks”
                 expression="payload.iced ? 'coldDrinks' :
        'hotDrinks'” />




A Router consumes a Message from one Channel and republishes it to a
      different Channel channel depending on a set of conditions.

                                   CONFIDENTIAL                        14
Batch

Producer and Consumer can run at independent times
         <int:channel id="preparedDrinks"/>
         <int:aggregator
             input-channel="preparedDrinks"
             method="prepareDelivery"
             output-channel="deliveries” >
             <bean
         class="org.sf.integration.samples.cafe.xml.Waiter"/>
         </int:aggregator>




    Use a stateful filter, an Aggregator, to collect and store individual
 messages until a complete set of related messages has been received,
  then publish a single message distilled from the individual messages.

                                  CONFIDENTIAL                              15
Publish

Tell everyone who wants to know about this

              <int-event:outbound-channel-adapter
                      channel="eventChannel"/>




  All messages sent to the 'eventChannel' channel will be published as
 ApplicationEvents to any relevant ApplicationListener instances that are
          registered within the same Spring ApplicationContext.

                                 CONFIDENTIAL                               16
Modularity

Deploy, Scale, Version a distributed system
                 Local                          Distributed
<service-activator                 <int-amqp:outbound-gateway
  input-channel="coldDrinks”          id="coldDrinksBarista"
  ref="barista”                       request-channel="coldDrinks”
  method="prepareColdDrink”           reply-channel="preparedDrinks”
  output-channel="preparedDrinks” /> routing-key="ordered.drinks.cold” />
<service-activator                 <int-amqp:outbound-gateway
  input-channel="hotDrinks”           id="hotDrinksBarista"
  ref="barista"                       request-channel="hotDrinks”
  method="prepareHotDrink"            reply-channel="preparedDrinks”
  output-channel="preparedDrinks” /> routing-key="ordered.drinks.hot” />

 Spring Integration doesn’t force you to finalize decisions about deployment
 before testing begins. Individual modules can be versioned, deployed, and
     scaled independently at any time through configuration, not code.
                                   CONFIDENTIAL                            17
Advanced Message Queuing Protocol
            (AMQP)




              CONFIDENTIAL          18
Advanced Message Queuing Protocol


    “Like email, but you can
      send money over it”                Open, Ubiquitous,
                                          and Adaptable



        async        SMTP                       AMQP


        sync         HTTP                       IIOP

                    unreliable                  reliable

                                 CONFIDENTIAL                19
Why AMQP?

 A Protocol, not an API
 • A defined set of messaging
    capabilities called the AMQ
    model
 • A network wire-level
    protocol, AMQP

                                      On commodity hardware
                                      • 10-25 thousand messages
                                        per second is routine *
                                      • The NIC is usually the
                                        bottleneck

                                             * Non-persistent messages
                              CONFIDENTIAL                               20
Why AMQP?


AMQP security
• Brokers support separate
  virtual hosts
• Three levels of permissions
• AMQP over SSL is supported


                                               Designed to scale horizontally
                                               • Dozens of clustered brokers
                                                 are common
                                               • JPMorgan sends 1 billion
                                                 AMQP messages per day


                                CONFIDENTIAL                                21
AMQP Architecture




                                          new.order
        new.order    new.order
       routing key    binding           M1 M2 M3
                                           queue




                         CONFIDENTIAL                 22
AMQP Architecture




                            café deliveries

                      M1 M2 M3
                                   queue

                         café NA deliveries

                      M1 M2 M3
                                   queue

                         café WW deliveries

                      M1 M2 M3
                                   queue




                    CONFIDENTIAL              23
AMQP Architecture



                                                all_drinks

                                           1 2 3
                                                 queue


                         drink.cold            cold_drinks

                                           2
                                                 queue


                                               hot_drinks

                                           1
 Message Routing Keys:                           queue
 1. drink.hot
 2. drink.cold
 3. drink.warm
                            CONFIDENTIAL                     24
RabbitMQ




  CONFIDENTIAL   25
Legacy Middleware not suited for Modern Apps



      Apps &
    Middleware             Existing middleware impacts agility by tightly
                        coupling applications to underlying application server
                                 and other middleware components




   Costly to Scale Up         Complex to Scale Out    Licensed by Peak Physical Servers



                                       CONFIDENTIAL                                  26
RabbitMQ – Messaging that Just Works




     design goal: no bloat - “it just works”
          mission: “be everywhere”
               AMQP LEADER


                          CONFIDENTIAL         27
Incredible Community Lowers Your Cost of Use

    ! "##$ (0$ % #G% 0(#K(C 4. % $ G9(% (E8 4-C .
         % . -$ ,              (@/    KE, "i




          ! "##$ & ' `j <>("/ 0(& $ -4. 4R(2
               %                  :        g7(E"-% , -. +$
                                                 /       E


   A , (4^, -(E": T"?, . (F4-(C "/ K(4% -(= Q "i 4-C .
                                      +,     (E8




 ;8
  4G0("/ 0(W 8 ! G/ H "/ "?, (* $8 3, (C 4-, (. "8 .
            G$0H    &            8(0-$           ,
                             CONFIDENTIAL                    28
Enterprise Users, such as this Tier-1 Telco




                             CONFIDENTIAL     29
Enterprise Features, such as Clustering


                   RMQ Cluster1
                                  queue-1    RMQ1
             1

                                  queue-2    RMQ2
             2

                                  queue-3    RMQ3
             3


  1. queue-1
  2. queue-3
  3. queue-2
                              CONFIDENTIAL          30
Enterprise Features, such as Fault Tolerance




          ESX1
          VM1                                   VM2

                          RMQ1                                      RMQ2
                 hot-drinks
                  hot-drinks                          hot-drinks
                 cold-drinks
                 cold-drinks                          cold-drinks


 master
 slave


                                 CONFIDENTIAL                              31
Summary

• Modern Applications
   – Use frameworks, less emphasis on servers
   – The explosion of connected mobile devices
     requires a new solution for messaging
• Spring Integration
   – A DSL for introducing messaging abstractions
     into your spring application
   – Externalizes messaging concepts from code
• AMQP
   – A TCP/IP protocol not an API
   – Fast, Reliable, Open, Secure, Scalable
• RabbitMQ
   – AMQP Leader
   – Backed by VMware

                               CONFIDENTIAL         32
Messaging for Modern Applications

Pronam Chatterjee, Staff Systems Engineer, VMware
Email: pronamc@vmware.com
Twitter: pronamc




                                                                                  CONFIDENTIAL
                                                    © 2010 SpringSource, A division of VMware. All rights reserved

Mais conteúdo relacionado

Mais procurados

Windows Server 2008 R2 Overview 1225768142880746 9
Windows Server 2008 R2 Overview 1225768142880746 9Windows Server 2008 R2 Overview 1225768142880746 9
Windows Server 2008 R2 Overview 1225768142880746 9
Stephan - Gabriel Georgescu
 
Ws 2012 feature comparison hyper v
Ws 2012 feature comparison hyper vWs 2012 feature comparison hyper v
Ws 2012 feature comparison hyper v
Ramakrishnan M
 
Scvmm 2012 (maarten wijsman)
Scvmm 2012 (maarten wijsman)Scvmm 2012 (maarten wijsman)
Scvmm 2012 (maarten wijsman)
hypervnu
 
Am 04 track1--salvatore orlando--openstack-apac-2012-final
Am 04 track1--salvatore orlando--openstack-apac-2012-finalAm 04 track1--salvatore orlando--openstack-apac-2012-final
Am 04 track1--salvatore orlando--openstack-apac-2012-final
OpenCity Community
 

Mais procurados (20)

Windows Server 2008 R2 Overview 1225768142880746 9
Windows Server 2008 R2 Overview 1225768142880746 9Windows Server 2008 R2 Overview 1225768142880746 9
Windows Server 2008 R2 Overview 1225768142880746 9
 
Planning for MQ in the cloud MQTC 2017
Planning for MQ in the cloud MQTC 2017Planning for MQ in the cloud MQTC 2017
Planning for MQ in the cloud MQTC 2017
 
Interconnect 2017: 6893 Keep out the bad guys by securing your MQ messaging e...
Interconnect 2017: 6893 Keep out the bad guys by securing your MQ messaging e...Interconnect 2017: 6893 Keep out the bad guys by securing your MQ messaging e...
Interconnect 2017: 6893 Keep out the bad guys by securing your MQ messaging e...
 
Ws 2012 feature comparison hyper v
Ws 2012 feature comparison hyper vWs 2012 feature comparison hyper v
Ws 2012 feature comparison hyper v
 
Designing IBM MQ deployments for the cloud generation
Designing IBM MQ deployments for the cloud generationDesigning IBM MQ deployments for the cloud generation
Designing IBM MQ deployments for the cloud generation
 
Where is My Message
Where is My MessageWhere is My Message
Where is My Message
 
Connecting mq&amp;kafka
Connecting mq&amp;kafkaConnecting mq&amp;kafka
Connecting mq&amp;kafka
 
Scvmm 2012 (maarten wijsman)
Scvmm 2012 (maarten wijsman)Scvmm 2012 (maarten wijsman)
Scvmm 2012 (maarten wijsman)
 
Am 04 track1--salvatore orlando--openstack-apac-2012-final
Am 04 track1--salvatore orlando--openstack-apac-2012-finalAm 04 track1--salvatore orlando--openstack-apac-2012-final
Am 04 track1--salvatore orlando--openstack-apac-2012-final
 
IBM WebSphere MQ: Using Publish/Subscribe in an MQ Network
IBM WebSphere MQ: Using Publish/Subscribe in an MQ NetworkIBM WebSphere MQ: Using Publish/Subscribe in an MQ Network
IBM WebSphere MQ: Using Publish/Subscribe in an MQ Network
 
IBM MQ - High Availability and Disaster Recovery
IBM MQ - High Availability and Disaster RecoveryIBM MQ - High Availability and Disaster Recovery
IBM MQ - High Availability and Disaster Recovery
 
Secure Messages with IBM WebSphere MQ Advanced Message Security
Secure Messages with IBM WebSphere MQ Advanced Message SecuritySecure Messages with IBM WebSphere MQ Advanced Message Security
Secure Messages with IBM WebSphere MQ Advanced Message Security
 
IBM MQ vs Apache ActiveMQ
IBM MQ vs Apache ActiveMQIBM MQ vs Apache ActiveMQ
IBM MQ vs Apache ActiveMQ
 
IBM MQ in containers MQTC 2017
IBM MQ in containers MQTC 2017IBM MQ in containers MQTC 2017
IBM MQ in containers MQTC 2017
 
IBM MQ V8 Security
IBM MQ V8 SecurityIBM MQ V8 Security
IBM MQ V8 Security
 
Hybrid Messaging with MQ Light, MQ's Beta Support for AMQP, and IBM Bluemix
Hybrid Messaging with MQ Light, MQ's Beta Support for AMQP, and IBM BluemixHybrid Messaging with MQ Light, MQ's Beta Support for AMQP, and IBM Bluemix
Hybrid Messaging with MQ Light, MQ's Beta Support for AMQP, and IBM Bluemix
 
CloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 Preview
CloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 PreviewCloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 Preview
CloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 Preview
 
Quantum Networks
Quantum NetworksQuantum Networks
Quantum Networks
 
IBM WebSphere MQ: Managing Workloads, Scaling and Availability with MQ Clusters
IBM WebSphere MQ: Managing Workloads, Scaling and Availability with MQ ClustersIBM WebSphere MQ: Managing Workloads, Scaling and Availability with MQ Clusters
IBM WebSphere MQ: Managing Workloads, Scaling and Availability with MQ Clusters
 
IBM MQ: Using Publish/Subscribe in an MQ Network
IBM MQ: Using Publish/Subscribe in an MQ NetworkIBM MQ: Using Publish/Subscribe in an MQ Network
IBM MQ: Using Publish/Subscribe in an MQ Network
 

Destaque

Collaboration between special and general education teachers
Collaboration between special and general education teachersCollaboration between special and general education teachers
Collaboration between special and general education teachers
Sofia Effraimidou
 
Dalai lama delhi_dialogue_05_jan2011
Dalai lama delhi_dialogue_05_jan2011Dalai lama delhi_dialogue_05_jan2011
Dalai lama delhi_dialogue_05_jan2011
LindaAtSama
 
Analysis of Background PAH levels in East Anglia
Analysis of Background PAH levels in East AngliaAnalysis of Background PAH levels in East Anglia
Analysis of Background PAH levels in East Anglia
mpaccount
 
Site Specific Assessment using G-CAT and AGS file structure
Site Specific Assessment using G-CAT and AGS file structureSite Specific Assessment using G-CAT and AGS file structure
Site Specific Assessment using G-CAT and AGS file structure
mpaccount
 

Destaque (10)

Collaboration between special and general education teachers
Collaboration between special and general education teachersCollaboration between special and general education teachers
Collaboration between special and general education teachers
 
Dalai lama delhi_dialogue_05_jan2011
Dalai lama delhi_dialogue_05_jan2011Dalai lama delhi_dialogue_05_jan2011
Dalai lama delhi_dialogue_05_jan2011
 
Analysis of Background PAH levels in East Anglia
Analysis of Background PAH levels in East AngliaAnalysis of Background PAH levels in East Anglia
Analysis of Background PAH levels in East Anglia
 
Social media and healthcare fall 2013
Social media and healthcare fall 2013 Social media and healthcare fall 2013
Social media and healthcare fall 2013
 
Social media and modern healthcare
Social media and modern healthcareSocial media and modern healthcare
Social media and modern healthcare
 
Site Specific Assessment using G-CAT and AGS file structure
Site Specific Assessment using G-CAT and AGS file structureSite Specific Assessment using G-CAT and AGS file structure
Site Specific Assessment using G-CAT and AGS file structure
 
What Is G Cat
What Is G CatWhat Is G Cat
What Is G Cat
 
V fabric overview
V fabric overviewV fabric overview
V fabric overview
 
e-patients
e-patientse-patients
e-patients
 
Hype vs. Reality: The AI Explainer
Hype vs. Reality: The AI ExplainerHype vs. Reality: The AI Explainer
Hype vs. Reality: The AI Explainer
 

Semelhante a Messaging for modern applications

SALSA: A Framework for Dynamic Configuration of Cloud Services
SALSA: A Framework for Dynamic Configuration of Cloud ServicesSALSA: A Framework for Dynamic Configuration of Cloud Services
SALSA: A Framework for Dynamic Configuration of Cloud Services
Duc-Hung LE
 
Reliable Messaging /Guaranteed delivery
Reliable Messaging /Guaranteed deliveryReliable Messaging /Guaranteed delivery
Reliable Messaging /Guaranteed delivery
WSO2
 
Russell spring one2gx_messaging_india
Russell spring one2gx_messaging_indiaRussell spring one2gx_messaging_india
Russell spring one2gx_messaging_india
GaryPRussell
 
IBM Managing Workload Scalability with MQ Clusters
IBM Managing Workload Scalability with MQ ClustersIBM Managing Workload Scalability with MQ Clusters
IBM Managing Workload Scalability with MQ Clusters
IBM Systems UKI
 

Semelhante a Messaging for modern applications (20)

Scalability and Reliability in the Cloud
Scalability and Reliability in the CloudScalability and Reliability in the Cloud
Scalability and Reliability in the Cloud
 
Orchestration Patterns for Microservices with Messaging by RabbitMQ
Orchestration Patterns for Microservices with Messaging by RabbitMQOrchestration Patterns for Microservices with Messaging by RabbitMQ
Orchestration Patterns for Microservices with Messaging by RabbitMQ
 
IBM IMPACT 2014 AMC-1866 Introduction to IBM Messaging Capabilities
IBM IMPACT 2014 AMC-1866 Introduction to IBM Messaging CapabilitiesIBM IMPACT 2014 AMC-1866 Introduction to IBM Messaging Capabilities
IBM IMPACT 2014 AMC-1866 Introduction to IBM Messaging Capabilities
 
Modern Cloud-Native Streaming Platforms: Event Streaming Microservices with K...
Modern Cloud-Native Streaming Platforms: Event Streaming Microservices with K...Modern Cloud-Native Streaming Platforms: Event Streaming Microservices with K...
Modern Cloud-Native Streaming Platforms: Event Streaming Microservices with K...
 
IBM IMPACT 2014 - AMC-1882 Building a Scalable & Continuously Available IBM M...
IBM IMPACT 2014 - AMC-1882 Building a Scalable & Continuously Available IBM M...IBM IMPACT 2014 - AMC-1882 Building a Scalable & Continuously Available IBM M...
IBM IMPACT 2014 - AMC-1882 Building a Scalable & Continuously Available IBM M...
 
Event Driven Architecture
Event Driven ArchitectureEvent Driven Architecture
Event Driven Architecture
 
Introducing the Open Container Project
Introducing the Open Container ProjectIntroducing the Open Container Project
Introducing the Open Container Project
 
Push to Me: Mobile Push Notifications (Zend Framework)
Push to Me: Mobile Push Notifications (Zend Framework)Push to Me: Mobile Push Notifications (Zend Framework)
Push to Me: Mobile Push Notifications (Zend Framework)
 
Pull, don’t push: Architectures for monitoring and configuration in a microse...
Pull, don’t push: Architectures for monitoring and configuration in a microse...Pull, don’t push: Architectures for monitoring and configuration in a microse...
Pull, don’t push: Architectures for monitoring and configuration in a microse...
 
Pull, Don't Push! Sensu Summit 2018 Talk
Pull, Don't Push! Sensu Summit 2018 TalkPull, Don't Push! Sensu Summit 2018 Talk
Pull, Don't Push! Sensu Summit 2018 Talk
 
Adaptiva OneSite Cloud: Software Delivery Everywhere
Adaptiva OneSite Cloud: Software Delivery EverywhereAdaptiva OneSite Cloud: Software Delivery Everywhere
Adaptiva OneSite Cloud: Software Delivery Everywhere
 
SALSA: A Framework for Dynamic Configuration of Cloud Services
SALSA: A Framework for Dynamic Configuration of Cloud ServicesSALSA: A Framework for Dynamic Configuration of Cloud Services
SALSA: A Framework for Dynamic Configuration of Cloud Services
 
Reliable Messaging /Guaranteed delivery
Reliable Messaging /Guaranteed deliveryReliable Messaging /Guaranteed delivery
Reliable Messaging /Guaranteed delivery
 
Rehosting apps between k8s clusters and automating deployment using crane c...
Rehosting apps between k8s clusters and automating deployment using crane   c...Rehosting apps between k8s clusters and automating deployment using crane   c...
Rehosting apps between k8s clusters and automating deployment using crane c...
 
Cloud: CDN Killer?
Cloud: CDN Killer? Cloud: CDN Killer?
Cloud: CDN Killer?
 
Russell spring one2gx_messaging_india
Russell spring one2gx_messaging_indiaRussell spring one2gx_messaging_india
Russell spring one2gx_messaging_india
 
Implementing a Solution to the Cloud Vendor Lock-In Using Standardized API
Implementing a Solution to the Cloud Vendor Lock-In Using Standardized APIImplementing a Solution to the Cloud Vendor Lock-In Using Standardized API
Implementing a Solution to the Cloud Vendor Lock-In Using Standardized API
 
IBM Managing Workload Scalability with MQ Clusters
IBM Managing Workload Scalability with MQ ClustersIBM Managing Workload Scalability with MQ Clusters
IBM Managing Workload Scalability with MQ Clusters
 
Mq Lecture
Mq LectureMq Lecture
Mq Lecture
 
Application Modernisation through Event-Driven Microservices
Application Modernisation through Event-Driven Microservices Application Modernisation through Event-Driven Microservices
Application Modernisation through Event-Driven Microservices
 

Último

Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Último (20)

Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

Messaging for modern applications

  • 1. Taking the next step shouldn’t be scary … Messaging for Modern Applications CONFIDENTIAL 1
  • 2. Messaging for Modern Applications Pronam Chatterjee, Staff Systems Engineer, VMware Email: pronamc@vmware.com Twitter: pronamc CONFIDENTIAL © 2010 SpringSource, A division of VMware. All rights reserved
  • 3. Session Agenda • Modern Applications – Trends and Impact on Messaging – Impact on Application Architecture • Spring Integration – Messaging Use Cases – Messaging DSL for Spring Applications • AMQP – Why AMQP? – AMQP Architecture • RabbitMQ – Why RabbitMQ? – RabbitMQ Architecture CONFIDENTIAL 3
  • 4. Modern Application Trends • Written with frameworks – Developer productivity and innovation • New Application Types – Mobile, SaaS, Social – Apps released early and often • Data intensive – Emerging requirements: elasticity, multi-cloud – Web orientation drives exponential data volumes • Deployed on virtual and cloud infrastructure – Trending toward hybrid (public and private) infrastructure CONFIDENTIAL 4
  • 5. Today’s Middleware and Databases Not Keeping Up Rise of Modern Developer Frameworks Service Loose Simplicity Polyglot Consumption Coupling Today’s Middleware and Databases Service Elastic Elastic Virtualization Delivery Deployment Scaling Aware Rise of Virtual and Cloud Infrastructure CONFIDENTIAL 5
  • 6. Modern Applications need Modern Messaging Traditional approaches to messaging imply predictable, static interaction between well-known end-points Modern approaches to messaging embrace the unpredictable, dynamic, and transient nature of the web CONFIDENTIAL 6
  • 7. Synchronous Architecture is Brittle An exception occurred, Manage please resend Inventory Place Fulfill Order Order X X X X X X X X X Schedule Delivery If any component is unavailable within this synchronous flow, all in-flight messages will be affected, regardless of what component they are currently in -- and since state is maintained across the components, the system can be complex to reset CONFIDENTIAL 7
  • 8. Asynchronous Architecture Rules the Web The status of your order is I can fulfill … part of that Order I have an Order I can fulfill part of Your order will that Order be delivered next Tuesday I’ll schedule delivery of that order In this asynchronous flow: • all state is kept in the simple messages being passed • each stateless component interacts only with the broker cloud • if a component is lost, only the in-flight messages within that component must be re-delivered • components can be quickly provisioned on-demand CONFIDENTIAL 8
  • 9. How is Messaging Used within Modern Apps?  Event I need to know when to do something  Fragment I need to only give you a piece of this data  Route Control who gets which message, without changing sender or receiver  Batch Producer and consumer can run at independent times  Publish Tell everyone who wants to know about this  Modularity Deploy, Scale, and Version a distributed system CONFIDENTIAL 9
  • 10. Spring Integration CONFIDENTIAL 10
  • 11. What is Spring Integration? • At the core, an embedded Message Bus – Inspired by Gregor Hohpe and Bobby Woolf's Enterprise Integration Patterns (2004) – Runs within any Spring ApplicationContext – All components are Spring-managed objects • Also, an Application Integration Framework – Connects to other systems via adapters – Unidirectional Channel Adapters – Bidirectional Messaging Gateways CONFIDENTIAL 11
  • 12. Event I need to know when to do something … <service-activator input-channel="hotDrinks” ref="barista" method="prepareHotDrink" output-channel="preparedDrinks” /> An Event-Driven Consumer is one that is automatically handed messages as they’re delivered on the channel. The receiver acts like the message delivery is an event that triggers the receiver into action. CONFIDENTIAL 12
  • 13. Fragment I need to only give you this piece of data … <int:splitter input-channel="orders” expression="payload.items” output-channel="drinks” /> Use a Splitter to break out the composite message into a series of individual messages, each containing data related to one item. CONFIDENTIAL 13
  • 14. Route Control who gets what message <int:router input-channel="drinks” expression="payload.iced ? 'coldDrinks' : 'hotDrinks'” /> A Router consumes a Message from one Channel and republishes it to a different Channel channel depending on a set of conditions. CONFIDENTIAL 14
  • 15. Batch Producer and Consumer can run at independent times <int:channel id="preparedDrinks"/> <int:aggregator input-channel="preparedDrinks" method="prepareDelivery" output-channel="deliveries” > <bean class="org.sf.integration.samples.cafe.xml.Waiter"/> </int:aggregator> Use a stateful filter, an Aggregator, to collect and store individual messages until a complete set of related messages has been received, then publish a single message distilled from the individual messages. CONFIDENTIAL 15
  • 16. Publish Tell everyone who wants to know about this <int-event:outbound-channel-adapter channel="eventChannel"/> All messages sent to the 'eventChannel' channel will be published as ApplicationEvents to any relevant ApplicationListener instances that are registered within the same Spring ApplicationContext. CONFIDENTIAL 16
  • 17. Modularity Deploy, Scale, Version a distributed system Local Distributed <service-activator <int-amqp:outbound-gateway input-channel="coldDrinks” id="coldDrinksBarista" ref="barista” request-channel="coldDrinks” method="prepareColdDrink” reply-channel="preparedDrinks” output-channel="preparedDrinks” /> routing-key="ordered.drinks.cold” /> <service-activator <int-amqp:outbound-gateway input-channel="hotDrinks” id="hotDrinksBarista" ref="barista" request-channel="hotDrinks” method="prepareHotDrink" reply-channel="preparedDrinks” output-channel="preparedDrinks” /> routing-key="ordered.drinks.hot” /> Spring Integration doesn’t force you to finalize decisions about deployment before testing begins. Individual modules can be versioned, deployed, and scaled independently at any time through configuration, not code. CONFIDENTIAL 17
  • 18. Advanced Message Queuing Protocol (AMQP) CONFIDENTIAL 18
  • 19. Advanced Message Queuing Protocol “Like email, but you can send money over it” Open, Ubiquitous, and Adaptable async SMTP AMQP sync HTTP IIOP unreliable reliable CONFIDENTIAL 19
  • 20. Why AMQP? A Protocol, not an API • A defined set of messaging capabilities called the AMQ model • A network wire-level protocol, AMQP On commodity hardware • 10-25 thousand messages per second is routine * • The NIC is usually the bottleneck * Non-persistent messages CONFIDENTIAL 20
  • 21. Why AMQP? AMQP security • Brokers support separate virtual hosts • Three levels of permissions • AMQP over SSL is supported Designed to scale horizontally • Dozens of clustered brokers are common • JPMorgan sends 1 billion AMQP messages per day CONFIDENTIAL 21
  • 22. AMQP Architecture new.order new.order new.order routing key binding M1 M2 M3 queue CONFIDENTIAL 22
  • 23. AMQP Architecture café deliveries M1 M2 M3 queue café NA deliveries M1 M2 M3 queue café WW deliveries M1 M2 M3 queue CONFIDENTIAL 23
  • 24. AMQP Architecture all_drinks 1 2 3 queue drink.cold cold_drinks 2 queue hot_drinks 1 Message Routing Keys: queue 1. drink.hot 2. drink.cold 3. drink.warm CONFIDENTIAL 24
  • 26. Legacy Middleware not suited for Modern Apps Apps & Middleware Existing middleware impacts agility by tightly coupling applications to underlying application server and other middleware components Costly to Scale Up Complex to Scale Out Licensed by Peak Physical Servers CONFIDENTIAL 26
  • 27. RabbitMQ – Messaging that Just Works design goal: no bloat - “it just works” mission: “be everywhere” AMQP LEADER CONFIDENTIAL 27
  • 28. Incredible Community Lowers Your Cost of Use ! "##$ (0$ % #G% 0(#K(C 4. % $ G9(% (E8 4-C . % . -$ , (@/ KE, "i ! "##$ & ' `j <>("/ 0(& $ -4. 4R(2 % : g7(E"-% , -. +$ / E A , (4^, -(E": T"?, . (F4-(C "/ K(4% -(= Q "i 4-C . +, (E8 ;8 4G0("/ 0(W 8 ! G/ H "/ "?, (* $8 3, (C 4-, (. "8 . G$0H & 8(0-$ , CONFIDENTIAL 28
  • 29. Enterprise Users, such as this Tier-1 Telco CONFIDENTIAL 29
  • 30. Enterprise Features, such as Clustering RMQ Cluster1 queue-1 RMQ1 1 queue-2 RMQ2 2 queue-3 RMQ3 3 1. queue-1 2. queue-3 3. queue-2 CONFIDENTIAL 30
  • 31. Enterprise Features, such as Fault Tolerance ESX1 VM1 VM2 RMQ1 RMQ2 hot-drinks hot-drinks hot-drinks cold-drinks cold-drinks cold-drinks master slave CONFIDENTIAL 31
  • 32. Summary • Modern Applications – Use frameworks, less emphasis on servers – The explosion of connected mobile devices requires a new solution for messaging • Spring Integration – A DSL for introducing messaging abstractions into your spring application – Externalizes messaging concepts from code • AMQP – A TCP/IP protocol not an API – Fast, Reliable, Open, Secure, Scalable • RabbitMQ – AMQP Leader – Backed by VMware CONFIDENTIAL 32
  • 33. Messaging for Modern Applications Pronam Chatterjee, Staff Systems Engineer, VMware Email: pronamc@vmware.com Twitter: pronamc CONFIDENTIAL © 2010 SpringSource, A division of VMware. All rights reserved