summaryrefslogtreecommitdiffstats
path: root/yardstick/cmd/cli.py
diff options
context:
space:
mode:
authorrexlee8776 <limingjiang@huawei.com>2017-02-27 10:49:57 +0000
committerrexlee8776 <limingjiang@huawei.com>2017-02-28 08:27:54 +0000
commit806008ab5f3bc912c9c23d4c1fff6253a50e77ed (patch)
tree0f0dd8c9b4000df19007ff3ff5520dd7f4d8bf5b /yardstick/cmd/cli.py
parent177feabf43564afd28c7b4112ad4e384a3654bd8 (diff)
stream default INFO, filehdr default DEBUG
The DEBUG log can be stored as file and pushed into artifacts. Default sys.out level should be INFO. Stream level can be changed to DEBUG if cli "-d" is enabled. remove "-v" since it's not useful for a test framework JIRA: YARDSTICK-507 Change-Id: I3caafd31a2caac73b0e3f33c2762c090e76c707e Signed-off-by: rexlee8776 <limingjiang@huawei.com>
Diffstat (limited to 'yardstick/cmd/cli.py')
-rw-r--r--yardstick/cmd/cli.py13
1 files changed, 3 insertions, 10 deletions
diff --git a/yardstick/cmd/cli.py b/yardstick/cmd/cli.py
index 6281bb813..1f8dfee2d 100644
--- a/yardstick/cmd/cli.py
+++ b/yardstick/cmd/cli.py
@@ -20,7 +20,7 @@ from pkg_resources import get_distribution
from argparse import RawDescriptionHelpFormatter
from oslo_config import cfg
-from yardstick import _init_logging, LOG
+from yardstick import _init_logging, _LOG_STREAM_HDLR
from yardstick.cmd.commands import task
from yardstick.cmd.commands import runner
from yardstick.cmd.commands import scenario
@@ -33,11 +33,7 @@ cli_opts = [
cfg.BoolOpt('debug',
short='d',
default=False,
- help='increase output verbosity to debug'),
- cfg.BoolOpt('verbose',
- short='v',
- default=False,
- help='increase output verbosity to info')
+ help='increase output verbosity to debug')
]
CONF.register_cli_opts(cli_opts)
@@ -132,11 +128,8 @@ class YardstickCLI():
def _handle_global_opts(self):
_init_logging()
- if CONF.verbose:
- LOG.setLevel(logging.INFO)
-
if CONF.debug:
- LOG.setLevel(logging.DEBUG)
+ _LOG_STREAM_HDLR.setLevel(logging.DEBUG)
def _dispath_func_notask(self):