Appendix B. Moving Forward

In this appendix, we'll try to gather as much extra information as possible for those willing to go further from this point.

Even though we covered a lot of ground in this book, the Play! Framework 2 hasn't been covered entirely; there are yet some places to be discovered that wouldn't fit in this book—most of them are for advanced users, and some more specific to Scala.

This appendix will relate information about the following topics:

  • Play's features and internals that weren't covered
  • Features that were covered, but roughly or quickly introduced
  • Advanced features to ignite interest
  • Play's ecosystem
  • Play's communities—interesting blogs and groups

More features

Even though you have reached this point after reading the entire book and hacking with all the features introduced, Play! Framework 2 still has some areas where goodies can be learned.

Plugin

The first thing worth mentioning is its internal architecture, which is completely modular. This allows Play 2 to provide developers with a range of end-points to integrate an application perfectly with the framework; for instance, the application life cycle, or its configuration.

These modules are called plugins (as always) and a specific API is available for creating our own. This API not only enables a developer to hook on the application itself, but also helps define global components that can be used along with the whole application. Mostly, they are used for integrating third-party libraries.

Global

Another API is also available for those developers willing to interact with the application with a reduced set of needs; it is completely related to the application itself. This API is called global settings . For more information for the Java part on the 2.0.4 Version, go to http://www.playframework.com/documentation/2.1.0/JavaGlobal.

So far, so good; those APIs are there to extend the application's capabilities in some way. However, there are even more features that a regular Play! 2 application can offer.

Session, cache, and i18n

The two features that are really important for scalable applications are the session-like functionality of a request and the caching system API, available out of the box.

The former enables a request to add or remove session information; this information is stored in the cookie until it expires and, on the other hand, short-lived data can also be consumed using flash scopes. For more information on the Scala part (2.0.4 Version), go to http://www.playframework.org/documentation/2.0.4/ScalaSessionFlash.

For shared data, or for other use cases like that, we could use the cache API that gives the ability to store or fetch data to a centralized destination, which is independent of the user or the request. For more information, check this page (still Version 2.0.4) for Java: http://www.playframework.org/documentation/2.0.4/JavaCache.

We didn't cover natural language and the classic internationalization (i18n) problem, but Play! Framework 2 already has everything covered for us. See http://www.playframework.org/documentation/2.0.4/ScalaI18N.

Frontend languages

In this book we introduced CoffeeScript, but didn't spend enough time on it to grasp every single advantage of it. So, I'd recommend browsing this documentation: http://arcturo.github.com/library/coffeescript/index.html.

We didn't use LESS CSS here, but it's probably one of the best ways to achieve DRYness styling rules for a web application. This language aims to import all missing features to CSS, such as variables or functions. It's very easy to understand, and everything is documented at http://lesscss.org/.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset