latest json utils logging 'Max serialization depth exceeded' errors

Bug #1140133 reported by Dan Prince
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Dan Prince
oslo-incubator
Fix Released
High
Dan Prince
Grizzly
Fix Released
High
Dan Prince

Bug Description

Using Nova Grizzly... with the latest jsonutils sync from openstack common I'm now seeing the following errors in api.log:

ERROR nova.openstack.common.jsonutils [-] Max serialization depth exceeded on object: 4 {'vm_state': u'active', 'availability_zone': None, 'terminated_at': None, 'ephemeral_gb': 0L, 'instance_type_id': 2L, 'user_data': None, 'vm_mode': None, 'deleted_at': None, 'reservation_id': u'r-hg5852o1', 'id': 23L, 'security_groups': [<nova.db.sqlalchemy.models.SecurityGroup object at 0x5bbf490>], 'disable_terminate': False, 'root_device_name': u'/dev/vda', 'user_id': u'52478460e2914a7a958b1c64e1cfcbda', 'uuid': u'32fe3701-df8e-40c9-a0f8-3a991480c7a2', 'default_swap_device': None, 'info_cache': <nova.db.sqlalchemy.models.InstanceInfoCache object at 0x5149c90>, 'hostname': u'test', 'launched_on': u'nova1', 'display_description': u'test', 'key_data': None, 'deleted': 0L, 'config_drive': u'', 'power_state': 1L, 'default_ephemeral_device': None, 'progress': 0, 'project_id': u'aa0e59701d3948c3aed0642bfef3e046', 'launched_at': datetime.datetime(2013, 3, 2, 2, 40, 55), 'scheduled_at': datetime.datetime(2013, 3, 2, 2, 40, 32), 'node': u'nova1', 'ramdisk_id': 'ea1d7fa2-b722-4625-8daf-0fb13eec373a', 'access_ip_v6': None, 'access_ip_v4': None, 'kernel_id': '773f795a-99ed-47ff-afd1-3e6403ae980f', 'key_name': None, 'updated_at': datetime.datetime(2013, 3, 2, 2, 41, 25, 444743), 'host': u'nova1', 'extra_specs': {}, 'display_name': u'fog', 'system_metadata': [<nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5125a50>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149110>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149ed0>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149c50>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149210>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x51490d0>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149b50>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149050>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149490>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149910>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149290>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149090>, <nova.db.sqlalchemy.models.InstanceSystemMetadata object at 0x5149a90>], 'task_state': 'rebuilding', 'shutdown_terminate': False, 'cell_name': None, 'root_gb': 0L, 'locked': False, 'name': 'instance-00000017', 'created_at': datetime.datetime(2013, 3, 2, 2, 40, 32), 'launch_index': 0L, 'memory_mb': 512L, 'instance_type': <nova.db.sqlalchemy.models.InstanceTypes object at 0x5bbfc90>, 'vcpus': 1L, 'image_ref': u'd5270c8c-8847-4af3-bb38-f45c56ed9abd', 'architecture': None, 'auto_disk_config': None, 'os_type': None, 'metadata': [<nova.db.sqlalchemy.models.InstanceMetadata object at 0x4e50a50>]}

----

https://github.com/openstack/nova/commit/7b206ad53d0ecfb9176a3c47e574552998caa0f7#nova/openstack/common/jsonutils.py

I do not believe the extra LOG.error in that commit should be there... (our code doesn't support that ATM due to nested instance refs, etc)

Dan Prince (dan-prince)
Changed in nova:
assignee: nobody → Dan Prince (dan-prince)
importance: Undecided → High
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

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

Revision history for this message
Mark McLoughlin (markmc) wrote :

Merged into Oslo here: https://review.openstack.org/23342

Changed in oslo:
status: New → Fix Committed
importance: Undecided → High
assignee: nobody → Dan Prince (dan-prince)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/23343
Committed: http://github.com/openstack/nova/commit/e6f6a61d8da252c8c13da09ddf092c5c23ac61c7
Submitter: Jenkins
Branch: master

commit e6f6a61d8da252c8c13da09ddf092c5c23ac61c7
Author: Dan Prince <email address hidden>
Date: Sat Mar 2 10:19:40 2013 -0500

    Don't LOG.error on max_depth (by default).

    Reverts part of 7b206ad which added an extra LOG.error
    statement when max_depth is hit.

    This is causing spurious errors to get logged when making
    some Nova requests.

    Fixes LP Bug #1140133

    Change-Id: I0fff47d9c53c63345ae273a4d20a2bacb27f12e5

Changed in nova:
status: In Progress → Fix Committed
Mark McLoughlin (markmc)
Changed in oslo:
milestone: none → grizzly-rc1
Thierry Carrez (ttx)
Changed in oslo:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: none → grizzly-rc1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: grizzly-rc1 → 2013.1
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.