java - logback xml configuration for web application -
i using logback slf4j logging debug/error statements. please let me know how use single logback.xml configuration file multiple environments (dev/qa/prod)? right now, editing xml file each environment specify dbname...i appreciate help.
couple of options (most of them documented here)
- use properties in log configuration set externally (either java properties or os environment variables)
- use jndi settings (creating db datasources pretty common)
- generate logback.xml file part of deployment process
- jmx configurator allows reload configuration named file
- package war file each environment (don't recommend included completeness)
Comments
Post a Comment