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.

In REST the goal is the URL + Method (GET / PUT / POST / DELETE) is
sufficient to determine the action being taken. For our "/action" API
endpoints this is very far from the case.

        -Sean

-- 
Sean Dague
Samsung Research America
[email protected] / [email protected]
http://dague.net

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
OpenStack-dev mailing list
[email protected]
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

Reply via email to