Before you can implement your own functionality in a module, you should know how to create and build a module. This recipe takes a look at the module's structure and should give you a good start.
The source code of the example is available at
It is pretty easy to create a new module. Go into any directory and enter the following:
play new-module firstmodule
This creates a directory called
and copies a set of predefined files into it. By copying these files, you can create a package and create this module ready to use for other Play applications. Now, you can run
play build-module and your module is built. The build step implies compiling your Java code, ...