Bug 1022351

Summary: log-enable option ignored in config file when used also in command line
Product: Red Hat Enterprise MRG Reporter: Pavel Moravec <pmoravec>
Component: qpid-cppAssignee: messaging-bugs <messaging-bugs>
Status: CLOSED NOTABUG QA Contact: MRG Quality Engineering <mrgqe-bugs>
Severity: low Docs Contact:
Priority: high    
Version: 2.3CC: cknapp, jross, pmoravec, tross
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-10-23 19:58:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Pavel Moravec 2013-10-23 06:45:59 UTC
Description of problem:
When specifying "log-enable" option both in command line and in configuration file, the option in command line is silently ignored.

This is low severity but high priority bug, as it delays customer problem investigation due to troubleshooting why adding the option to config file does not enable the desire logging.


Version-Release number of selected component (if applicable):
any (checked on 0.22-19 and 0.18-14)


How reproducible:
100%


Steps to Reproduce:
echo "log-enable=trace+" > qpidd.conf
qpidd --config qpidd.conf --log-enable info+ 2>&1 | grep trace


Actual results:
no output


Expected results:
trace logs like:
2013-10-23 06:44:00 [Model] trace Mgmt create memory. id:amqp-broker

to appear


Additional info:
moving the option from config.file to command line causes it is applied properly

Comment 1 Ted Ross 2013-10-23 13:30:31 UTC
The description and the reproducer are inconsistent.  You said the command-line option is silently ignored but the reproducer shows that the command line supersedes the configuration file.

I believe that this is the desired and expected behavior.  The configuration system takes input from the config file, the command line, and the environment variables.  In cases where there are conflicts, the command line takes precedence over the configuration file.

Comment 2 Justin Ross 2013-10-23 17:45:50 UTC
I agree, command-line config is expected to supercede the config file.  Needinfoing the reporter.

(In reply to Ted Ross from comment #1)
> The description and the reproducer are inconsistent.  You said the
> command-line option is silently ignored but the reproducer shows that the
> command line supersedes the configuration file.
> 
> I believe that this is the desired and expected behavior.  The configuration
> system takes input from the config file, the command line, and the
> environment variables.  In cases where there are conflicts, the command line
> takes precedence over the configuration file.

Comment 3 Pavel Moravec 2013-10-23 19:58:26 UTC
Wrong problem description - _config_ option is ignored.

I havent realized the behaviour of command line precedence applies also to the `log-enable` option that can be specified multiple times.

Closing BZ as not a bug.