An intuitive guide to creating easy-to-build scalable web applications using the Play frameworkAbout This BookMaster the complexity of designing a modern and scalable Web application by leveraging the Play framework stackThe key concepts of the framework are illustrated with both Scala and Java code examplesA step-by-step guide with code examples based on a sample application built from the ground up, providing the practical skills required to develop Scala- or Java-based applications.Who This Book Is ForThis book targets Java and Scala developers who already have some experience in web development and who want to master Play framework quickly and efficiently. This book assumes you have a good level of knowledge and understanding of efficient Java and Scala code.
What You Will LearnSet up a unified development environment for both the client-side and server-side codeUnderstand the challenges of building a scalable web application and master the solutions provided by Play frameworkIntegrate the framework with existing client-side or server-side technologies such as persistence systemsHarness the reactive programming model to process data streamsDesign robust, maintainable, and testable codeBe proficient in manipulating JSON data blobsDeploy your application on a PaaS platformIn DetailPlay is a framework to write web applications using Scala or Java. It provides a productive development environment, allowing you to just hit the "refresh" button in your browser to compile your changes and reload the application. Because of its stateless nature, the framework makes it easy to build applications that scale. Play provides a reactive programming model to harness the event-driven HTTP layer.
This book provides a step-by-step walkthrough of how to build a complete web application following best application development practices using Play framework 2. All aspects specific to web-oriented architectures are the HTTP layer, JSON manipulation, HTML templating, asset compression and concatenation, form submission, content negotiation, security, and HTTP streaming. The book will also provide detailed architectural insights into Play framework to give you a better understanding in order to successfully build scalable applications.
I learned quite a bit about Play, though most of what I learned feels like "guess I need to go learn Scala?" As the title suggests, the book does a pretty good job of laying out the essential parts of Play Framework (the foundational components, tools, and techniques), but I feel like you're only going to get a "scratch the surface" view of Play unless you're already familiar with Scala. Granted: Play also comes in a "plain Java" flavor, and the author includes equivalent examples (where possible) that are in Java, but these wind up feeling more like a distraction -- like you keep context switching.
I really feel like this book could have been made much better by two things:
(1) A quick introduction to Scala -- just like the quick introduction to Groovy that shows up as Chapter 2 of Grails in Action.
(2) Drop the Java examples -- or move them into some kind of appendix. They just feel like they distract from the main point. (And honestly, I just skipped most of them.)
As the book stands right now, it seems like it's a pretty good introduction to Play (again: I learned most of what I was hoping to learn) but it does gloss over some points, and (more importantly) if you don't know Scala, you're probably going to feel a little lost.