NSX: log request body to NSX as debug

Previously we never logged the request body that we sent to NSX. This makes
things hard to debug when issues arise as we don't actually log the body of
the request that we made. This patch adds the body to our issue request log
statement.

Change-Id: I7d98e3d844ebe565fb5919aac3f9afd5b4040e69
Closes-bug: 1360394
This commit is contained in:
Aaron Rosen 2014-08-22 11:09:29 -07:00
parent 9ddc2267a8
commit 2bc898ff7a

View File

@ -86,8 +86,10 @@ class ApiRequest(object):
return error return error
url = self._url url = self._url
LOG.debug(_("[%(rid)d] Issuing - request %(conn)s"), LOG.debug(_("[%(rid)d] Issuing - request url: %(conn)s "
{'rid': self._rid(), 'conn': self._request_str(conn, url)}) "body: %(body)s"),
{'rid': self._rid(), 'conn': self._request_str(conn, url),
'body': self._body})
issued_time = time.time() issued_time = time.time()
is_conn_error = False is_conn_error = False
is_conn_service_unavail = False is_conn_service_unavail = False