Skip to content

mConfig Documentation

mConfig is a modular Java library for unified, portable configuration management. It abstracts OS-specific locations (e.g., ~/.config/, /etc/, Windows Registry), multiple sources (files, env vars, JAR resources, ZooKeeper), and formats (JSON, YAML, TOML, Properties, etc.). The mConfig Tool is a powerful companion for exploring and managing these configurations from the command line.

Core Principle: Layered resolution stack prioritizes scopes (highest first):

graph LR
  POLICY[POLICY<br/>Enforced/GPO] --> RUNTIME[RUNTIME<br/>Volatile RAM]
  RUNTIME --> SESSION[SESSION<br/>Env/CLI]
  SESSION --> USER[USER<br/>~/.config/]
  USER --> APPLICATION[APPLICATION<br/>Portable/Install]
  APPLICATION --> HOST[HOST<br/>/etc/, HKLM]
  HOST --> CLUSTER[CLUSTER<br/>ZK/Networks]
  CLUSTER --> CLOUD[CLOUD<br/>Providers]
  CLOUD --> ORGANIZATION[ORGANIZATION<br/>Licensee]
  ORGANIZATION --> PRODUCT[PRODUCT<br/>JAR Defaults]

  classDef high fill:#ff9999
  class POLICY,RUNTIME high

Ties within scope: Later-added > earlier; storage prio: RAM > secrets > files > registry > JAR.

Quick Start: What is mConfig?Getting Started

Architecture: Design Consolidated

Part 1: Introduction & Basics

Part 2: Core Concepts

Part 3: Advanced Topics

Part 4: Reference & Project