You may want to consider YAML
The Dropwizard framework in Java uses YAML for its external configuration. This is easier to work with than JSON since there are no braces.
You can use Jackson to unmarshal the YAML into DTOs with the Jackson Data format YAML module.
Here is an example YAML configuration for configuring the SLF4J within Dropwizard:
logging:
level: WARN
# Logger-specific levels.
loggers:
# Set specific levels
"com.sun.jersey.api.client": DEBUG
"com.yammer": INFO
"org.multibit": DEBUG
# ...
# Settings for logging to stdout.
console:
# If true, write log statements to stdout.
enabled: true
# Do not display log statements below this threshold to stdout.
threshold: ALL
# Settings for logging to a file.
file:
# If true, write log statements to a file.
enabled: false
# Do not write log statements below this threshold to the file.
threshold: ALL
# The file to which current statements will be logged.
currentLogFilename: /var/log/example/developer.log
# When the log file rotates, the archived log will be renamed to this and gzipped. The
# %d is replaced with the previous day (yyyy-MM-dd). Custom rolling windows can be created
# by passing a SimpleDateFormat-compatible format as an argument: "%d{yyyy-MM-dd-hh}".
archivedLogFilenamePattern: /var/log/example/developer-%d.log.gz
# The number of archived files to keep.
archivedFileCount: 5
# The timezone used to format dates. HINT: USE THE DEFAULT, UTC.
timeZone: UTC