Modularize configuration handling