posted by Sean Middleditch on August 24th, 2010 - 9:44am PDT
A new module, ConfigBuilder, is available in the Sugar PEAR repository.
ConfigBuilder is a small and simple configuration engine for PHP apps. It consists of a XML configuration file format and a utility, aptly named config-builder, that compiles the XML format into a compact serialized text format that can be quickly loaded and used by a PHP application.
While the source XML format allows for hierarchal configuration, includes, overrides, and config key expansion, the serialized format is a flat map of key names to values. This makes configuration values extremely quick to load and use, which is important given the frequency the configuration is read and accessed in a typical application.