unify logging setup on all services
This provides a single setup_logging function which builds consistent
colorization if the config supports it, otherwise builds the identity
strings that we need to actually keep track of requests.
Change-Id: Iffe30326a5b974ad141aed6288f61e0d6fd18ca9
diff --git a/lib/cinder b/lib/cinder
index cf5bb25..870ee0b 100644
--- a/lib/cinder
+++ b/lib/cinder
@@ -333,12 +333,7 @@
iniset $CINDER_CONF DEFAULT volume_clear $CINDER_VOLUME_CLEAR
# Format logging
- if [ "$LOG_COLOR" == "True" ] && [ "$SYSLOG" == "False" ] && [ "$CINDER_USE_MOD_WSGI" == "False" ]; then
- setup_colorized_logging $CINDER_CONF
- else
- # Set req-id, project-name and resource in log format
- iniset $CINDER_CONF DEFAULT logging_context_format_string "%(asctime)s.%(msecs)03d %(levelname)s %(name)s [%(request_id)s %(project_name)s] %(resource)s%(message)s"
- fi
+ setup_logging $CINDER_CONF $CINDER_USE_MOD_WSGI
if [ "$CINDER_USE_MOD_WSGI" == "True" ]; then
_cinder_config_apache_wsgi