Change in vdsm[master]: BindingXMLRPC: flowID for Irs calls

dougsland at redhat.com dougsland at redhat.com
Thu Jan 17 19:30:44 UTC 2013


Douglas Schilling Landgraf has uploaded a new change for review.

Change subject: BindingXMLRPC: flowID for Irs calls
......................................................................

BindingXMLRPC: flowID for Irs calls

Adding flowID to vdsm log for Irs calls

Change-Id: Icffc8f4f4bdbcf96f99bdb5608e46410c5f23e23
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=800355
Signed-off-by: Douglas Schilling Landgraf <dougsland at redhat.com>
---
M vdsm/BindingXMLRPC.py
1 file changed, 11 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/64/11164/1

diff --git a/vdsm/BindingXMLRPC.py b/vdsm/BindingXMLRPC.py
index 0e37e1f..00529a0 100644
--- a/vdsm/BindingXMLRPC.py
+++ b/vdsm/BindingXMLRPC.py
@@ -159,6 +159,17 @@
     def _registerFunctions(self):
         def wrapIrsMethod(f):
             def wrapper(*args, **kwargs):
+                # Logging current call
+                logStr = 'client [%s]::call %s with %s %s' % \
+                    (getattr(f.im_self.cif.threadLocal, 'client', ''),
+                    f.__name__, args, kwargs)
+
+                # if flowID exists
+                if getattr(f.im_self.cif.threadLocal, 'flowID', None) is not None:
+                    logStr += " flowID [%s]" % f.im_self.cif.threadLocal.flowID
+
+                f.im_self.log.log(logging.DEBUG, logStr)
+
                 if self.cif.threadLocal.client:
                     f.im_self.log.debug('[%s]', self.cif.threadLocal.client)
                 try:


--
To view, visit http://gerrit.ovirt.org/11164
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Icffc8f4f4bdbcf96f99bdb5608e46410c5f23e23
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Douglas Schilling Landgraf <dougsland at redhat.com>


More information about the vdsm-patches mailing list