You often have to create environment-specific configurations for your Play Framework applications. But how can you manage your configurations in the best possible way? We’ll show you in this article.
This post is the second in the series of publications about using the Apache ZooKeeper for building configuration management solutions for a distributed system. It focuses on implementing a tool for loading initial configuration data into a fresh ZooKeeper ensemble.
One of the steps towards building a successful distributed software system is establishing effective configuration management. It is a complex engineering process which is responsible for planning, identifying, tracking and verifying changes in the software and its configuration as well as maintaining configuration integrity throughout the life cycle of the system.
Let's consider how to store and manage configuration settings of the entire system and its components using Apache ZooKeeper, a high-performance coordination service for distributed applications.
This code snippet shows how to update project configuration settings from a Grails plugin executable script. The script changes the configuration by copying the settings from a default config file, placed in the plugin's folder, to the Config.groovy. This is usually very useful during a plugin installation when you need to provide some default configuration: