fuel-devops output sometimes is messed up

Bug #1661342 reported by Dennis Dmitriev on 2017-02-02
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Undecided
Dennis Dmitriev

Bug Description

SSHClient in fuel-devops uses 'print' function to verbose the output of the execution a remote command.

But the output of 'print' function can be in wrong order towards the logger.info output.

Example of the current output (pay attention to the strings with "Executing command:...". The command with "apt-get-update" should be in the step #2; all the output before it - from the step #1): http://paste.openstack.org/show/597506/

This is how it is expected: http://paste.openstack.org/show/597507/

In the first example above, steps headers "[ Install ...]" are shown with logger.info() method, all the rest - with print() function.

In the second example, print() is also replaced with logger.info() and looks fine.

Fix proposed to branch: master
Review: https://review.openstack.org/428305

Changed in fuel:
assignee: nobody → Dennis Dmitriev (ddmitriev)
status: New → In Progress
description: updated
description: updated

Reviewed: https://review.openstack.org/428305
Committed: https://git.openstack.org/cgit/openstack/fuel-devops/commit/?id=ee2ede88d461fddf0b1a3cba21cfa40997b5c254
Submitter: Jenkins
Branch: master

commit ee2ede88d461fddf0b1a3cba21cfa40997b5c254
Author: Dennis Dmitriev <email address hidden>
Date: Thu Feb 2 20:00:02 2017 +0200

    Replace 'print' with 'logger.info()' in command executors

    To avoid wrong ordering of the output lines, use the same output
    method logger.info() in SSHClient and Subprocess from helpers.

    - use logger.info and logger.error in case 'verbose=True'
    - use logger.debug for stdout and stderr in case 'verbose=False'

    Change-Id: I31c6355eed1d945422585d9be5199933e0d3ab3f
    Closes-Bug:#1661342

Changed in fuel:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers