vdsm icon indicating copy to clipboard operation
vdsm copied to clipboard

mpathconf: fix read_blacklist use of logging library

Open aesteve-rh opened this issue 3 years ago • 1 comments

Currently, read_blacklist is using logging to log warnings to the console. But the function is called from the tool.config_lvm_filter module, so the logs will be hidden when using vdsm-tool.

We can fix it now and return some additional information that can be processed by the config_lvm_filter module and print the correct logs into sys.stdout.

Note that there is https://github.com/oVirt/vdsm/issues/258, which could allow passing the right logging context through a parameter as an alternate solution.

aesteve-rh avatar Jun 29 '22 12:06 aesteve-rh

Passing a logger sounds like the right approach.

nirs avatar Jun 29 '22 12:06 nirs