connection_trace does not work with DB2 backend

Bug #1274523 reported by Matt Riedemann on 2014-01-30
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Undecided
Jay Bryant
OpenStack Compute (nova)
Low
Eugeniya Kudryashova
oslo-incubator
Medium
Brant Knudson
oslo.db
Undecided
Unassigned

Bug Description

When setting connection_trace=True, the stack trace does not get printed for DB2 (ibm_db).

I have a patch that we've been using internally for this fix that I plan to upstream soon, and with that we can get output like this:

2013-09-11 13:07:51.985 28151 INFO sqlalchemy.engine.base.Engine [-] SELECT services.created_at AS services_created_at, services.updated_at AS services_updated_at, services.deleted_at AS services_deleted_at, services.deleted AS services_deleted, services.id AS services_id, services.host AS services_host, services."binary" AS services_binary, services.topic AS services_topic, services.report_count AS services_report_count, services.disabled AS services_disabled, services.disabled_reason AS services_disabled_reason
FROM services WHERE services.deleted = ? AND services.id = ? FETCH FIRST 1 ROWS ONLY
2013-09-11 13:07:51,985 INFO sqlalchemy.engine.base.Engine (0, 3)
2013-09-11 13:07:51.985 28151 INFO sqlalchemy.engine.base.Engine [-] (0, 3)
        File /usr/lib/python2.6/site-packages/nova/servicegroup/drivers/db.py:92 _report_state() service.service_ref, state_catalog)
        File /usr/lib/python2.6/site-packages/nova/conductor/api.py:270 service_update() return self._manager.service_update(context, service, values)
        File /usr/lib/python2.6/site-packages/nova/openstack/common/rpc/common.py:420 catch_client_exception() return func(*args, **kwargs)
        File /usr/lib/python2.6/site-packages/nova/conductor/manager.py:461 service_update() svc = self.db.service_update(context, service['id'], values)
        File /usr/lib/python2.6/site-packages/nova/db/sqlalchemy/api.py:505 service_update() with_compute_node=False, session=session)
        File /usr/lib/python2.6/site-packages/nova/db/sqlalchemy/api.py:388 _service_get() result = query.first()

Tags: db Edit Tag help
Matt Riedemann (mriedem) on 2014-01-30
Changed in oslo:
assignee: nobody → Matt Riedemann (mriedem)
Matt Riedemann (mriedem) on 2014-01-30
Changed in oslo:
assignee: Matt Riedemann (mriedem) → nobody
Changed in nova:
assignee: nobody → Matt Riedemann (mriedem)
status: New → Confirmed

Fix proposed to branch: master
Review: https://review.openstack.org/70163

Changed in oslo:
assignee: nobody → Brant Knudson (blk-u)
status: New → In Progress
Dolph Mathews (dolph) on 2014-01-30
Changed in keystone:
importance: Undecided → Low
Jay Bryant (jsbryant) on 2014-01-30
Changed in cinder:
status: New → Confirmed
assignee: nobody → Jay Bryant (jsbryant)
Brant Knudson (blk-u) on 2014-01-30
Changed in keystone:
assignee: nobody → Brant Knudson (blk-u)
Feilong Wang (flwang) on 2014-02-02
Changed in glance:
status: New → Triaged
importance: Undecided → Low
assignee: nobody → Fei Long Wang (flwang)
Xu Han Peng (xuhanp) on 2014-02-24
Changed in neutron:
assignee: nobody → Xu Han Peng (xuhanp)
status: New → Confirmed
lvdongbing (dbcocle) on 2014-02-24
Changed in heat:
assignee: nobody → lvdongbing (dbcocle)
Changed in oslo:
importance: Undecided → Medium

Change abandoned by Brant Knudson (<email address hidden>) on branch: master
Review: https://review.openstack.org/92182
Reason: Taken care of by https://review.openstack.org/#/c/106406/

Brant Knudson (blk-u) wrote :

This was fixed in oslo.db by Michael Bayer with https://review.openstack.org/#/c/106406/

Changed in oslo:
status: In Progress → Fix Committed
no longer affects: keystone
Brant Knudson (blk-u) wrote :

Keystone isn't affected since all we have to do is pick up an oslo.db that includes https://review.openstack.org/#/c/106406/

Viktor Serhieiev (vsergeyev) wrote :

Is it still affects Glace?

Matt Riedemann (mriedem) wrote :

This should be fixed in nova when nova starts using oslo.db:

https://review.openstack.org/#/c/101901/

Changed in nova:
importance: Undecided → Low
status: Confirmed → In Progress
Changed in nova:
assignee: Matt Riedemann (mriedem) → Eugeniya Kudryashova (ekudryashova)
Thierry Carrez (ttx) on 2014-09-05
Changed in oslo-incubator:
status: Fix Committed → Fix Released
milestone: none → juno-3

Reviewed: https://review.openstack.org/101901
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=1b83b2f11054ddd3f72fe75c5cef496060afcb3a
Submitter: Jenkins
Branch: master

commit 1b83b2f11054ddd3f72fe75c5cef496060afcb3a
Author: Andrey Kurilin <email address hidden>
Date: Sat Jun 21 13:56:42 2014 +0300

    Move to oslo.db

    Replace common oslo code nova.openstack.common.db by usage
    of oslo.db library and remove common code.

    Replaced catching of raw sqlalchemy exceptions by catches
    of oslo.db exceptions(such as DBError, DBDuplicateEntry, etc).

    Co-Authored-By: Eugeniya Kudryashova <email address hidden>

    Closes-Bug: #1364986
    Closes-Bug: #1353131
    Closes-Bug: #1283987
    Closes-Bug: #1274523
    Change-Id: I0649539e071b2318ec85ed5d70259c949408e64b

Changed in nova:
status: In Progress → Fix Committed
Viktor Serhieiev (vsergeyev) wrote :

This was fixed in oslo.db by Michael Bayer with https://review.openstack.org/#/c/106406/

Changed in oslo.db:
status: New → Fix Committed
Changed in oslo.db:
milestone: none → 1.0.0
Thierry Carrez (ttx) on 2014-09-18
Changed in oslo.db:
status: Fix Committed → Fix Released
Zane Bitter (zaneb) on 2014-09-25
Changed in heat:
importance: Undecided → Low
status: New → Triaged
Thierry Carrez (ttx) on 2014-10-01
Changed in nova:
milestone: none → juno-rc1
status: Fix Committed → Fix Released
Thierry Carrez (ttx) on 2014-10-16
Changed in nova:
milestone: juno-rc1 → 2014.2

Closing stale bug. If this is still an issue please reopen.

Changed in cinder:
status: Confirmed → Invalid
Thomas Herve (therve) on 2016-07-08
no longer affects: heat

Closing stale bug. If this is still an issue please reopen.

no longer affects: neutron

FWIW, DB2 support got removed from Nova in Newton, see release notes of "14.0.0.0b1" http://docs.openstack.org/releasenotes/nova/index.html

Matt Riedemann (mriedem) on 2016-07-16
no longer affects: glance
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers