SlideShare a Scribd company logo
1 of 18
Play2
Ein flexibles Full-Stack Framework
für skalierbare Webanwendungen
        http://www.playframework.com
Martin Grotzke
                                           inoio gmbh

                              Twitter: @martin_grotzke
                                Web: http://inoio.de




Play2 ... für skalierbare Webanwendungen                 2/18
For the impatient...

            “Play is a high-productivity Java and Scala
            web application framework [..] based on a
            lightweight, stateless, web-friendly
            architecture and features predictable and
            minimal resource consumption (CPU, memory,
            threads) for highly-scalable applications.”
            http://www.playframework.com/documentation/2.1.1/Home




Play2 ... für skalierbare Webanwendungen                            3/18
JEE Complexity




                                           Servlet API

                                 Mojarra ...             JS
                                                         F
                                   Facelets         Seam

                                           Application



Play2 ... für skalierbare Webanwendungen                      4/18
Play simply


                     Servlet API

             Mojarra ...              JS            Play Framework
                                      F
              Facelets          Seam                  Application

                     Application



                 Architecture of the World Wide Web, Volume One,
                 W3C, 2004 http://www.w3.org/TR/webarch/


Play2 ... für skalierbare Webanwendungen                             5/18
Cloud




Play2 ... für skalierbare Webanwendungen           6/18
Play Elastic




Play2 ... für skalierbare Webanwendungen         7/18
Realtime




Play2 ... für skalierbare Webanwendungen         8/18
Realtime




Play2 ... für skalierbare Webanwendungen         9/18
Play async




Play2 ... für skalierbare Webanwendungen        10/18
Productivity




Play2 ... für skalierbare Webanwendungen         11/18
Productivity




“On our next similar project, we'll be able to deliver 30% cost savings over
the Java bid [..]. And remember, these numbers come after paying
developers more.”
http://thinkrelevance.com/blog/2005/12/20/bidding-projects-with-ruby-rails-take-2


 Play2 ... für skalierbare Webanwendungen                                           12/18
Productivity
                                                                                        2x

Martin Fowler: Is Ruby More Productive?
  http://martinfowler.com/articles/rubyAtThoughtWorks.html




                         How much did Ruby improve productivity for this project? (Compared to the best mainstream tools you know.)



  Play2 ... für skalierbare Webanwendungen                                                                               13/18
Play full stack

                                               Akka      DB
                                 WebSockets           Evolutions

                         Async I/O                          Persistence




                   Java                                                    Scala

                           sbt                                     Templates
                                                                   +JSON/XML

                             Dev, Test, Prod              Asset
                             Environments
                                                   HTTP Compiler
                                           Testing Server


Play2 ... für skalierbare Webanwendungen                                           14/18
Play demo




Play2 ... für skalierbare Webanwendungen    15/18
Play reality check

 ●   IDE Support: Continuously improved
 ●   Hot Code Reloading: Compile time + app reload
 ●   Async: More async drivers needed




Play2 ... für skalierbare Webanwendungen             16/18
Play is...

            “a high-productivity Java and Scala web
            application framework [..] based on a
            lightweight, stateless, web-friendly
            architecture and features predictable and
            minimal resource consumption (CPU, memory,
            threads) for highly-scalable applications.”
            http://www.playframework.com/documentation/2.1.1/Home




Play2 ... für skalierbare Webanwendungen                            17/18
Questions!
                 @martin_grotzke
                 http://inoio.de




Play2 ... für skalierbare Webanwendungen   18/18

More Related Content

Similar to Play2 Framework für skalierbare Webanwendungen

Viridians on Rails
Viridians on RailsViridians on Rails
Viridians on RailsViridians
 
Running your Java EE applications in the Cloud
Running your Java EE applications in the CloudRunning your Java EE applications in the Cloud
Running your Java EE applications in the CloudArun Gupta
 
Camel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel KCamel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel KNicola Ferraro
 
Running your Java EE 6 applications in the clouds
Running your Java EE 6 applications in the clouds Running your Java EE 6 applications in the clouds
Running your Java EE 6 applications in the clouds Arun Gupta
 
Server Side Javascript
Server Side JavascriptServer Side Javascript
Server Side Javascriptrajivmordani
 
We4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshell
We4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshellWe4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshell
We4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshellWe4IT Group
 
Five cool ways the JVM can run Apache Spark faster
Five cool ways the JVM can run Apache Spark fasterFive cool ways the JVM can run Apache Spark faster
Five cool ways the JVM can run Apache Spark fasterTim Ellison
 
Isomorphic JavaScript with Nashorn
Isomorphic JavaScript with NashornIsomorphic JavaScript with Nashorn
Isomorphic JavaScript with NashornMaxime Najim
 
The Cloud-natives are RESTless @ JavaOne
The Cloud-natives are RESTless @ JavaOneThe Cloud-natives are RESTless @ JavaOne
The Cloud-natives are RESTless @ JavaOneKonrad Malawski
 
Predictable reactive state management for enterprise apps using NGRX/platform
Predictable reactive state management for enterprise apps using NGRX/platformPredictable reactive state management for enterprise apps using NGRX/platform
Predictable reactive state management for enterprise apps using NGRX/platformIlia Idakiev
 
Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009Arun Gupta
 
WebGL games with Minko - Next Game Frontier 2014
WebGL games with Minko - Next Game Frontier 2014WebGL games with Minko - Next Game Frontier 2014
WebGL games with Minko - Next Game Frontier 2014Minko3D
 
Java and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystemJava and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystemRafael Winterhalter
 
Simplify and Boost Spark 3 Deployments with Hypervisor-Native Kubernetes
Simplify and Boost Spark 3 Deployments with Hypervisor-Native KubernetesSimplify and Boost Spark 3 Deployments with Hypervisor-Native Kubernetes
Simplify and Boost Spark 3 Deployments with Hypervisor-Native KubernetesDatabricks
 
Deep Dive Java 17 Devoxx UK
Deep Dive Java 17 Devoxx UKDeep Dive Java 17 Devoxx UK
Deep Dive Java 17 Devoxx UKJosé Paumard
 
[Unite Seoul 2019] Mali GPU Architecture and Mobile Studio
[Unite Seoul 2019] Mali GPU Architecture and Mobile Studio [Unite Seoul 2019] Mali GPU Architecture and Mobile Studio
[Unite Seoul 2019] Mali GPU Architecture and Mobile Studio Owen Wu
 
Die Qual der Wahl bei den Single Page Application Frameworks
Die Qual der Wahl bei den Single Page Application FrameworksDie Qual der Wahl bei den Single Page Application Frameworks
Die Qual der Wahl bei den Single Page Application FrameworksJonas Bandi
 

Similar to Play2 Framework für skalierbare Webanwendungen (20)

Viridians on Rails
Viridians on RailsViridians on Rails
Viridians on Rails
 
Running your Java EE applications in the Cloud
Running your Java EE applications in the CloudRunning your Java EE applications in the Cloud
Running your Java EE applications in the Cloud
 
Camel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel KCamel Day Italia 2021 - Camel K
Camel Day Italia 2021 - Camel K
 
Running your Java EE 6 applications in the clouds
Running your Java EE 6 applications in the clouds Running your Java EE 6 applications in the clouds
Running your Java EE 6 applications in the clouds
 
Node.js an Exectutive View
Node.js an Exectutive ViewNode.js an Exectutive View
Node.js an Exectutive View
 
Server Side Javascript
Server Side JavascriptServer Side Javascript
Server Side Javascript
 
We4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshell
We4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshellWe4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshell
We4IT LCTY 2013 - x-pages-men - ibm domino xpages - performance in a nutshell
 
Five cool ways the JVM can run Apache Spark faster
Five cool ways the JVM can run Apache Spark fasterFive cool ways the JVM can run Apache Spark faster
Five cool ways the JVM can run Apache Spark faster
 
Cloudy Ajax 08 10
Cloudy Ajax 08 10Cloudy Ajax 08 10
Cloudy Ajax 08 10
 
Isomorphic JavaScript with Nashorn
Isomorphic JavaScript with NashornIsomorphic JavaScript with Nashorn
Isomorphic JavaScript with Nashorn
 
The Cloud-natives are RESTless @ JavaOne
The Cloud-natives are RESTless @ JavaOneThe Cloud-natives are RESTless @ JavaOne
The Cloud-natives are RESTless @ JavaOne
 
Running Spark in Production
Running Spark in ProductionRunning Spark in Production
Running Spark in Production
 
Predictable reactive state management for enterprise apps using NGRX/platform
Predictable reactive state management for enterprise apps using NGRX/platformPredictable reactive state management for enterprise apps using NGRX/platform
Predictable reactive state management for enterprise apps using NGRX/platform
 
Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009
 
WebGL games with Minko - Next Game Frontier 2014
WebGL games with Minko - Next Game Frontier 2014WebGL games with Minko - Next Game Frontier 2014
WebGL games with Minko - Next Game Frontier 2014
 
Java and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystemJava and OpenJDK: disecting the ecosystem
Java and OpenJDK: disecting the ecosystem
 
Simplify and Boost Spark 3 Deployments with Hypervisor-Native Kubernetes
Simplify and Boost Spark 3 Deployments with Hypervisor-Native KubernetesSimplify and Boost Spark 3 Deployments with Hypervisor-Native Kubernetes
Simplify and Boost Spark 3 Deployments with Hypervisor-Native Kubernetes
 
Deep Dive Java 17 Devoxx UK
Deep Dive Java 17 Devoxx UKDeep Dive Java 17 Devoxx UK
Deep Dive Java 17 Devoxx UK
 
[Unite Seoul 2019] Mali GPU Architecture and Mobile Studio
[Unite Seoul 2019] Mali GPU Architecture and Mobile Studio [Unite Seoul 2019] Mali GPU Architecture and Mobile Studio
[Unite Seoul 2019] Mali GPU Architecture and Mobile Studio
 
Die Qual der Wahl bei den Single Page Application Frameworks
Die Qual der Wahl bei den Single Page Application FrameworksDie Qual der Wahl bei den Single Page Application Frameworks
Die Qual der Wahl bei den Single Page Application Frameworks
 

Recently uploaded

CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
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
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
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
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 

Recently uploaded (20)

CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
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
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
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?
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
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
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 

Play2 Framework für skalierbare Webanwendungen

  • 1. Play2 Ein flexibles Full-Stack Framework für skalierbare Webanwendungen http://www.playframework.com
  • 2. Martin Grotzke inoio gmbh Twitter: @martin_grotzke Web: http://inoio.de Play2 ... für skalierbare Webanwendungen 2/18
  • 3. For the impatient... “Play is a high-productivity Java and Scala web application framework [..] based on a lightweight, stateless, web-friendly architecture and features predictable and minimal resource consumption (CPU, memory, threads) for highly-scalable applications.” http://www.playframework.com/documentation/2.1.1/Home Play2 ... für skalierbare Webanwendungen 3/18
  • 4. JEE Complexity Servlet API Mojarra ... JS F Facelets Seam Application Play2 ... für skalierbare Webanwendungen 4/18
  • 5. Play simply Servlet API Mojarra ... JS Play Framework F Facelets Seam Application Application Architecture of the World Wide Web, Volume One, W3C, 2004 http://www.w3.org/TR/webarch/ Play2 ... für skalierbare Webanwendungen 5/18
  • 6. Cloud Play2 ... für skalierbare Webanwendungen 6/18
  • 7. Play Elastic Play2 ... für skalierbare Webanwendungen 7/18
  • 8. Realtime Play2 ... für skalierbare Webanwendungen 8/18
  • 9. Realtime Play2 ... für skalierbare Webanwendungen 9/18
  • 10. Play async Play2 ... für skalierbare Webanwendungen 10/18
  • 11. Productivity Play2 ... für skalierbare Webanwendungen 11/18
  • 12. Productivity “On our next similar project, we'll be able to deliver 30% cost savings over the Java bid [..]. And remember, these numbers come after paying developers more.” http://thinkrelevance.com/blog/2005/12/20/bidding-projects-with-ruby-rails-take-2 Play2 ... für skalierbare Webanwendungen 12/18
  • 13. Productivity 2x Martin Fowler: Is Ruby More Productive? http://martinfowler.com/articles/rubyAtThoughtWorks.html How much did Ruby improve productivity for this project? (Compared to the best mainstream tools you know.) Play2 ... für skalierbare Webanwendungen 13/18
  • 14. Play full stack Akka DB WebSockets Evolutions Async I/O Persistence Java Scala sbt Templates +JSON/XML Dev, Test, Prod Asset Environments HTTP Compiler Testing Server Play2 ... für skalierbare Webanwendungen 14/18
  • 15. Play demo Play2 ... für skalierbare Webanwendungen 15/18
  • 16. Play reality check ● IDE Support: Continuously improved ● Hot Code Reloading: Compile time + app reload ● Async: More async drivers needed Play2 ... für skalierbare Webanwendungen 16/18
  • 17. Play is... “a high-productivity Java and Scala web application framework [..] based on a lightweight, stateless, web-friendly architecture and features predictable and minimal resource consumption (CPU, memory, threads) for highly-scalable applications.” http://www.playframework.com/documentation/2.1.1/Home Play2 ... für skalierbare Webanwendungen 17/18
  • 18. Questions! @martin_grotzke http://inoio.de Play2 ... für skalierbare Webanwendungen 18/18

Editor's Notes

  1. Herzlich Willkommen zum Vortrag über Playframework 2 Mein Name ist Martin Grotzke -> [next slide]
  2. Webentwicklung mit Java seit mehr als 10 Jahren 2002 noch eigenes Servlet-Framework entwickelt Später dann Struts eingesetzt, JSF, Tapestry, Wicket, Spring MVC, GWT usw , neuerdings auch mal Rails Viele Jahre in Hamburger Softwarehaus gearbeitet, Projekte: libri, buch.de, smatch.com, tchibo Vor 2 Jahren eigene Firma gegründet Eigenes Produkt mit Play1, nun 2 Projekte mit Play2 _ Soviel zu mir... _ Was mich zu Beginn interessiert: Wer hat schonmal mit Play gearbeitet? Wer ist alles Java Entwickler? Wer schon mit Frameworks wie Rails oder Django? Nun möchte ich erstmal Play mit wenigen Worten einführen...
  3. * High-productivity * Lightweight * Stateless * Web-friendly (RESTful) * Effizient * Sehr gut skalierbar Ist Open Source Play1: 2007, Play2: 2012, nun bei Typesafe -> Das ist der Überblick über die nächsten 50 Minuten, wobei ich den Fokus dann auf die Produktivität lege. Im Folgenden stelle ich aktuelle Herausforderungen und Lösungen von Play gegenüber. Anfang: Komplexität bei Java Webentwicklung
  4. * Servlets (1997): Abstraktion der Web-Konzepte, Java-freundliche API (Web-Konzepte benennen!) * Komplexität u. Einschränkungen der Servlet-API: Gefixt mit zusätzlichen Schichten/Abstraktionen, mit Web-Frameworks wie JSF, Wicket, Spring-MVC, GWT etc. * Schwächen von JSF -> Seam => neue Abstraktionen * Weitere Dimension v. Komplexität durch Specs vs. Implementierungen -> Was gibt die Spec vor, was ist “Vendor-spezifisch”? * Diese Schichten/Abstraktionen/Specs/Implementierungen muss ich als Webdev durchdringen/verstehen, d.h. Ich muss einige Hürden/Stufen nehmen, um mein Ziel zu erreichen * -> Erschwert eher als zu erleichtern Lösung von Play? Anhang - Spezifikationen und Implementierungen: JAX-RS (Jersey, CXF, RESTEasy), JAX-WS 2.0/2.1/2.2 (Metro, Axis, CXF), JSF (Mojarra, MyFaces, PrimeFaces, ICEFaces), JSP, JSTL, WebProfiles, CDI, JPA 1/2, JMS, JTA, JCA.... Specs: das Ergebnis einer Expert Group von Vertretern unterschiedlicher Firmen mit unterschiedlichen Interessen (nicht immer Developer-orientiert) Dieser Wald will beherrscht werden
  5. Play: * losgelöst von Servlet Spec * Nicht mehrere Schichten, keine künstlichen Abstraktionen, sondern einfache und intuitive HTTP-API * Direktes Arbeiten mit Web-Konzepten * -> Wenn ich weiß, wie das Web funtioniert, habe ich schon einen großen Teil von Play verstanden - klick - * Gute Lektüre zu Web-Architektur: “Architecture of the World Wide Web, Volume One”, W3C, 2004 (http://www.w3.org/TR/webarch/) Nächste Herausforderung: Cloud / horizontale Skalierbarkeit
  6. Cloud / Elastizität: statt feste Zahl Server für max. Last werden je nach Bedarf die benötigten Ressourcen alloziert * Problem: Serverseitige Sessions (User, Warenkorb, ViewState) * Requests eines Besuchers müssen vom selben App-Server beantwortet werden -> Sticky Sessions (Kopplung mit LB) * Wenn Server aus Last-Verteilung genommen wird wären dessen Sessions verloren -> Session Replikation * Problem Session Replikation: oft nur begrenzt skalierbar, sehr komplex, zerbrechlich / nicht sehr robust Fazit: serverseitige Sessions stehen im Konflikt mit Elastizität/ dynamischer Skalierung Lösung von Play, wer hätte es gedacht, ist stateless zu arbeiten
  7. Play ist stateless, arbeitet ohne serverseitige Sessions – dem share-nothing Prinzip folgend * Jeder Request kann von jedem App-Server bearbeitet werden * Keine Session Replikation notwendig * Es können problemlos neue Server in Last-Verteilung aufgenommen oder herausgenommen werden * Elastisch, sehr gut dynamisch und horizontal skalierbar * Session auch in Play, clientseitig gelöst (signierter Cookie) Next: Realtime Webapps
  8. Beispiele: RT Dashboards (Google Analytics), Google Docs, Stock Ticker, Chat-Applikationen (Live Examples: http://en.lichess.org/ , http://live.gilt.com/ , http://console-demo.typesafe.com/ , https://docs.google.com ) Was ist die Herausforderung bei Realtime Anwendungen? Die Hohe Zahl von Clients, also gleichzeitige, lange bestehende Verbindungen, statt Request-/Response Zyklen -> Stichwort WebSockets
  9. Früher: Request-Verarbeitung mit Thread-per-Connection Modell Problem: * ein dedizierter Thread für einen Request, dieser Thread erledigt alle Arbeit für den Request bis die Response gesendet werden kann * I/O, typischerweise synchron/blocking, auch mit diesem Thread, d.h. dieser Thread ist blockiert und idle bis I/O abgeschlossen * (Randproblem: CPU context switches) * Konsequenz: es werden soviele Threads benötigt wie gleichzeitige Requests/Verbindungen bestehen ** -> RAM für Threads ** -> Ineffizient, schwer vorhersagbarer Ressourcenverbrauch, sehr begrenzt skalierbar * Bsp Threaded: Servlets, Rails, Django, PHP Weiter: Lösung von Play * Anhang: http://engineering.linkedin.com/play/play-framework-async-io-without-thread-pool-and-callback-hell http://www.scalaloader.org/2013/03/event-sourced-architecture-travelling_14.html http://de.slideshare.net/normanmaurer/netty4 http://www.kegel.com/c10k.html http://berb.github.io/diploma-thesis/original/042_serverarch.html
  10. Play: Event-basiertes Modell * typischerweise 1 Thread pro CPU Core * Idee: Threads werden nicht blockiert, d.h. I/O wird asynchron gemacht, und statt zu warten kann der Thread andere Requests verarbeiten. Wenn der I/O Aufruf fertig ist kann der Thread das Ergebnis aufnehmen und die Response an den Client ausliefern * Somit ist die Anzahl paralleler Verbindung nicht so stark durch Threads/Speicher begrenzt * Ok, seit Servlet Spec 3 auch async Requests, allerdings muss das jetzt erst von den verschiedenen Frameworks integriert/angebunden werden * Andere Event-driven Server: Node.js, Twisted * Für Request-Handling / NIO: Netty (bewährte NetworkingLib) * Intern Concurrency: Akka (Event-basiertes Middleware Framework f. nebenläufige u. verteilte Systeme) Event-driven -> Unterstützung von Streaming (Chunked transfer encoding, Comet, WebSockets) Next: Productivity
  11. Produktivität ist in der Java EE Welt eher mittelmäßig. Eine Ursache ist Komplexität, hatten wir schon. Anderer wichtiger Punkt: es müssen viele Werkzeuge miteinander kombiniert werden, z.B. Web-Framework, Template-Engine, IoC, Persistence, Testing-Libs, Remoting, evtl. Build-Tool etc. (ggf. nicht optimal aufeinander abgestimmt) Viele kleinere Ursachen, die ein flüssiges Arbeiten erschweren Produktivität schlägt sich in Entwicklungszeit nieder: Wenn man für ein Projekt anbietet und es Mitbewerber gibt, die z.B. mit Rails unterwegs sind, weiß man schon, dass die zu geringerem Preis anbieten können. Next: Rails: Batteries included
  12. Rails (oder auch Django) ist also eher das Smartphone, das alles mitbringt, was man braucht, man kann schnell seine Aufgaben erledigen -> “Batteries included” - klick - Statement einer Firma, die Rails neben Java eingeführt hat und deutliche Produktivitätssteigerungen festgestellt hat. * Sie verlangen höheren Tagessatz für Rails Entwicklung, sind schneller fertig, und Entwickler bekommen auch mehr Geld Anderes Beispiel ist Thoughtworks... [switch] Anhang: Eric Knipp, Research Director at Gartner: “Many high-profile consumer Web firms are choosing Ruby on Rails to rapidly build scalable web applications. Ruby on Rails has the potential to emerge as a strong alternative platform to traditional choices based on Java and .NET for next-generation enterprise applications, as companies seek improved agility, development speed and time to market.” http://www.businessinsider.com/heres-why-ruby-on-rails-is-hot-2011-5 We pay ourselves (and our contractors) better for Rails work than Java work. This is good for everybody: Developers have more fun, make more money, and customers get better products cheaper and faster.
  13. Martin Fowler hat bei Thoughtworks nach der Einführung von Rails bei den Teams/Team Leads nachgefragt, wie die Einschätzung bzgl. Produktivität sei Ergebnis: Peak bei doppelter Prod. Schon Fowler weist darauf hin, dass das natürlich mit Vorsicht zu genießen ist und es so gut wie unmöglich ist, objektive Auswertungen zu erhalten. Die Aussagen deuten aber darauf hin, dass es in jedem Fall Produktivitätssteigerungen gibt. Natürlich gibt's bei Rails auch Nachteile, wir arbeiten ja aus bestimmten (und auch guten) Gründen mit Java (z.B. Typsicherheit, Performance, Wartbarkeit) Hier kommt nun Play in's Spiel: es vereint die guten Seiten von Java / Scala mit den Vorteilen von Rails oder Django
  14. * Es bringt alles mit, was man zum Entwickeln einer Webapp braucht * RESTful MVC Framework (Template-Engine Twirl, like ASP.NET Razor, JSON/XML) * Persistenz-Framework * Asset-Compiler / Integration von Frontend-Technologien * Akka f. Nebenläufigkeit/Remote Kommunikation (Event-basiertes Middleware Framework f. nebenläufige u. verteilte Systeme) * Guter Testing Support (versch. Ebenen) * Build-Environment sbt mit incremental compilation / continuous Testing * Integrierter HTTP Server * Flexibel : einzelne Komponenten sind austauschbar * Native Unterstützung f. Java und Scala Das war Überblick über Full-Stack, nun mehr zu Produktivitäts-Features anhand von Source-Code
  15. Auch bei Play gibt es noch Potential: IDE Support (bei Eclipse) ist ok aber nicht perfekt – viel Entwicklung (IDEA Ultimate besser) Hot-Code Reloading: mit vielen Templates können die sich bemerkbar machen. Alternativen: Scalate (SCAML, Jade, Mustache), Jade, Velocity Async: Optimally backends would be accessed using NIO Check: async http client (play comes with a great wrapper for ning async http client) Check: Reactive Mongo JDBC: blocking interface - API, Driver, ConnPool, ORM/Libs Many other drivers are also blocking (SolrJ) Experimental non-blocking driver: adbcj, async-mysql-connector
  16. Um die Vorteile von Play noch einmal kurz zusammenzufassen... * Einfach/leichtgewichtig – nur 1 Framework, intuitive u. ausdrucksstarke HTTP API (web-friendly, RESTful) * Scalable – Stateless / sehr gut horizontal skalierbar / Elastisch / keine Probleme mit Elastizität * Effizient – durch async/non-blocking Request-Handling können viele Clients parallel bedient werden (RT) * Productive – hat sich viel von Rails/Django abgeschaut und kombiniert das mit vielen Compile-Time Checks - v.a. erwähnenswert Full-Stack, Hot-Code Reloading, kompilierte Templates+Routes, Evolutions, Integration Frontend-Technologien Damit vielen Dank für die Aufmerksamkeit, noch ein paar Minuten für Fragen