On Mon, Feb 10, 2014 at 3:11 PM, Sean Dague <[email protected]> wrote: > On 02/10/2014 05:05 PM, Christopher Yeoh wrote: > > On Mon, Feb 10, 2014 at 2:56 PM, Sean Dague <[email protected] > > <mailto:[email protected]>> wrote: > > > > In upstream Nova master we're currently logging ec2 wsgi requests > twice, > > once in the paste pipeline, and once in eventlet. > > > > The following patch removes the paste pipeline portion - > > https://review.openstack.org/#/c/67736/ > > > > However... I'm not very satisfied with this approach, as the > resulting > > log entries look as follows (lots more examples at - > > > http://logs.openstack.org/36/67736/7/check/check-tempest-dsvm-full/9b0eb3e/logs/screen-n-api.txt.gz?level=INFO > ) > > > > ... "POST /services/Cloud/ HTTP/1.1" status: 200 len: 2099 time: > > 0.8823061 > > ... "POST /services/Cloud/ HTTP/1.1" status: 200 len: 449 time: > > 0.1196980 > > ... "POST /services/Cloud/ HTTP/1.1" status: 200 len: 2095 time: > > 0.4743402 > > ... "POST /services/Cloud/ HTTP/1.1" status: 400 len: 360 time: > > 0.5385840 > > ... "POST /services/Cloud/ HTTP/1.1" status: 200 len: 449 time: > > 0.1317410 > > > > Because the eventlet logger is only logging the requestline (which is > > the URL), Post requests are basically completely information free. > > > > We have an equally opaque problem in the Nova API with server > actions: > > > > ... "POST > > > /v2/85979842c31049fab70bcdd399cb9a3f/servers/4d5c5ba0-a975-4f4b-863a-390ad58e1c48/action > > HTTP/1.1" status: 202 len: 185 time: 1.1360781 > > > > Because these aren't really RESTful interfaces, so the url is not > useful > > enough to determine the action. > > > > My feeling is that we need to make the wsgi request logs useful > enough > > to know what was actually called on an API call, which means I'm not > > convinced we can actually use the eventlet logger for Nova, because > our > > URLs aren't actually RESTful. > > > > I'm slightly surprised that in v3 we do the same thing. Could we at > > minimum change .... action urls to action/ACTIONNAME, or would that > > completely not work with our router? > > > > > > Yea this is a wsgi "thing". I guess we'll need to log action POSTs twice > > to get enough useful info in the logs. > > No, I get that our urls are POST .../action. :) > > What I'm saying is that isn't a RESTful url. The API end point should be > POST .../action/BLAH, and that's what attached to the controller. It > seems like given that we haven't yet released the v3 API this is maybe > changable. >
Hrm perhaps. Probably require a bit of hacking on wsgi to change how wsgi.action works and then a bunch of unittests and tempest tests updated to allow the patches to merge (unless we allow both types of behaviour in the meantime. However, for a RESTful url api design aren't you meant to avoid using verbs in the URL? Which is why I think the design was done this way in the first place. eg http://stackoverflow.com/questions/2447722/rest-services-exposing-non-data-actions so I'm not convinced we should be changing this. And feature propsal deadline is only a week away anyway. Chris
_______________________________________________ OpenStack-dev mailing list [email protected] http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
