WSGI requests in ir-api are reported with no log level and inconsistent date string

Bug #1507590 reported by Sean Dague
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ironic
Fix Released
Low
Unassigned

Bug Description

WSGI requests in ir-api are reported with no log level and a date string which is not consistent with the rest of the log:

Example:

http://logs.openstack.org/01/236901/1/check/gate-tempest-dsvm-ironic-agent_ssh/349672c/logs/screen-ir-api.txt.gz#_2015-10-19_11_30_22_584

2015-10-19 11:30:22.583 18979 DEBUG keystonemiddleware.auth_token [-] Authenticating user token process_request /usr/local/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py:478
2015-10-19 11:30:22.584 18979 DEBUG keystonemiddleware.auth_token [-] Received request from user: user_id bc729ccac6e54a52a9778149f892f521, project_id c02d0be4e2724497ab1fc6a94b5804d9, roles admin process_request /usr/local/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py:758
127.0.0.1 - - [19/Oct/2015 11:30:22] "GET /v1/nodes/detail?instance_uuid=425f3318-5236-4ead-baea-75df5905a965 HTTP/1.1" 200 9943
2015-10-19 11:30:22.639 18979 DEBUG keystonemiddleware.auth_token [-] Authenticating user token process_request /usr/local/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py:478
2015-10-19 11:30:22.641 18979 DEBUG keystonemiddleware.auth_token [-] Received request from user: user_id 14a89e56dc42451b86efaf721cf9dd28, project_id c77a1bf6d7114ac796f007b220a3672c, roles admin,Member,_member_ process_request /usr/local/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py:758
127.0.0.1 - - [19/Oct/2015 11:30:22] "GET /v1/nodes/79517f80-464c-4030-981a-790b457a8cb0 HTTP/1.1" 200 9776
2015-10-19 11:30:23.660 18979 DEBUG keystonemiddleware.auth_token [-] Authenticating user token process_request /usr/local/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py:478
2015-10-19 11:30:23.662 18979 DEBUG keystonemiddleware.auth_token [-] Received request from user: user_id 14a89e56dc42451b86efaf721cf9dd28, project_id c77a1bf6d7114ac796f007b220a3672c, roles admin,Member,_member_ process_request /usr/local/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py:758

Tags: api
Revision history for this message
Sean Dague (sdague) wrote :

The crux of this issue is that wsgiref.simple_server is used, which means default logging is very wonky.

http://stackoverflow.com/questions/31433682/control-wsgiref-simple-server-log - gives some hints on how to do this right.

Revision history for this message
Dmitry Tantsur (divius) wrote :

Note that switching to oslo.service might change the situation: https://bugs.launchpad.net/ironic/+bug/1484044

Changed in ironic:
status: New → Confirmed
importance: Undecided → Low
tags: added: api
Changed in ironic:
assignee: nobody → Zhenguo Niu (niu-zglinux)
assignee: Zhenguo Niu (niu-zglinux) → nobody
Changed in ironic:
assignee: nobody → Rahul U Nair (rahulunair)
Changed in ironic:
status: Confirmed → In Progress
Revision history for this message
Rahul U Nair (rahulunair) wrote :

Unassigning my self my from the bug.

Changed in ironic:
assignee: Rahul U Nair (rahulunair) → nobody
Revision history for this message
Dmitry Tantsur (divius) wrote :

The API logging has improved substantially with the switch to oslo.service, so I think we can call it done.

Changed in ironic:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.