Fork me on GitHub

Your application and modules can be configured using a simple text file. This file supports mode-sensitive keys and recursive includes.

# Include files serve as base settings which may be overridden in this file.
include = /path/to/, /path/to/ = Default Pippo Application = Developing Pippo Application = Testing Pippo Application = My Pippo Application

If a setting provides a mode-specific variant for the current runtime mode it's value will be used. Otherwise, the default setting's value will be used.

There is some flexibility in specifying from where to load your file.
This is the order Pippo will use to try to resolve an file:

  1. -Dpippo.settings=/path/to/ (flexible external location)
  2. $user.dir/ (the working directory of your application)
  3. conf/ (an embedded classpath resource)

An externally located file is automatically reloaded, if modified, on the next setting access within Pippo. This allows your Pippo application to be responsive without being restarted.

You can access programmatically your application settings using Application.get().getPippoSettings().