Add call tracing to exported libsuseconnect routines - #371
Conversation
Add a helper trace() routine to libsuseconnect that wraps calling util.Info.Printf() to print tracing messages for the majority of entry and exit paths in the exported routines. Tried using util.Debug rather than util.Info with debug output enabled but wasn't seeing any of the trace messages show up in the YaST2 logs.
55e131b to
2a1ef6a
Compare
Attempting to log a message in the set_log_callback() routine after having setup the callbackWriter() leads to a recursive deadlock at the Ruby level.
|
I don't think that we should write debug like this to stdout. And you can use util.Debug to write to the yast log file but it requires a couple of changes and yast needs to fix a bug that they have. These should result in the same behavior but they don't. YasT sends us clientParms of the form: when Y2DEBUG=1 The reference I found on the log.conf might be stale. It was from HPE docs and I don't see it in our docs. https://documentation.suse.com/sles/15-SP7/html/SLES-all/cha-yast-gui.html This is supposed to be away to enable this at boot time, but I have not tried it |
Add a helper trace() routine to libsuseconnect that wraps calling util.Info.Printf() to print tracing messages for the majority of entry and exit paths in the exported routines.
Tried using util.Debug rather than util.Info with debug output enabled but wasn't seeing any of the trace messages show up in the YaST2 logs.
Also need to avoid tracing the exit from the set_log_callback() routine as doing so can
cause a recursive deadlock failure at the Ruby level.
Implements: #363