_last_vol_usage_poll was not properly updated

Bug #1270693 reported by Haiwei Xu
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Critical
Russell Bryant
Havana
Fix Released
Undecided
Unassigned

Bug Description

I found this error in jinkins's log: http://logs.openstack.org/02/67402/4/check/gate-nova-python27/b132ac8/console.html

2014-01-20 02:36:59.295 | ======================================================================
2014-01-20 02:36:59.295 | FAIL: nova.tests.compute.test_compute.ComputeVolumeTestCase.test_poll_volume_usage_with_data
2014-01-20 02:36:59.295 | tags: worker-0
2014-01-20 02:36:59.296 | ----------------------------------------------------------------------
2014-01-20 02:36:59.296 | Empty attachments:
2014-01-20 02:36:59.296 | stderr
2014-01-20 02:36:59.296 | stdout
2014-01-20 02:36:59.297 |
2014-01-20 02:36:59.297 | pythonlogging:'': {{{
2014-01-20 02:36:59.297 | INFO [nova.virt.driver] Loading compute driver 'nova.virt.fake.FakeDriver'
2014-01-20 02:36:59.298 | AUDIT [nova.compute.resource_tracker] Auditing locally available compute resources
2014-01-20 02:36:59.298 | AUDIT [nova.compute.resource_tracker] Free ram (MB): 7680
2014-01-20 02:36:59.298 | AUDIT [nova.compute.resource_tracker] Free disk (GB): 1028
2014-01-20 02:36:59.299 | AUDIT [nova.compute.resource_tracker] Free VCPUS: 1
2014-01-20 02:36:59.299 | INFO [nova.compute.resource_tracker] Compute_service record created for fake-mini:fakenode1
2014-01-20 02:36:59.299 | AUDIT [nova.compute.manager] Deleting orphan compute node 2
2014-01-20 02:36:59.300 | }}}
2014-01-20 02:36:59.300 |
2014-01-20 02:36:59.300 | Traceback (most recent call last):
2014-01-20 02:36:59.300 | File "nova/tests/compute/test_compute.py", line 577, in test_poll_volume_usage_with_data
2014-01-20 02:36:59.301 | self.compute._last_vol_usage_poll)
2014-01-20 02:36:59.301 | File "/usr/lib/python2.7/unittest/case.py", line 420, in assertTrue
2014-01-20 02:36:59.301 | raise self.failureException(msg)
2014-01-20 02:36:59.302 | AssertionError: _last_vol_usage_poll was not properly updated <1390185067.18>

Revision history for this message
Matt Riedemann (mriedem) wrote :
Changed in nova:
status: New → Confirmed
importance: Undecided → Critical
tags: added: testing
Revision history for this message
Matt Riedemann (mriedem) wrote :
Revision history for this message
Matt Riedemann (mriedem) wrote :
Changed in nova:
status: Confirmed → In Progress
assignee: nobody → Russell Bryant (russellb)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/68768
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=7e18d67cc9c96a14e0ca24a41820441e41457738
Submitter: Jenkins
Branch: master

commit 7e18d67cc9c96a14e0ca24a41820441e41457738
Author: Russell Bryant <email address hidden>
Date: Thu Jan 23 16:03:37 2014 -0500

    Make test_poll_volume_usage_with_data more reliable

    This test includes 2 calls to time.time(). It assumes that the result
    from the second call may be greater than the first. This isn't
    definietly true and we see periodic failures of this test in the gate as
    a result.

    Change the test to not worry about the specific time value that gets
    set. We set _last_vol_usage_poll to 0 before calling the function under
    test. We really only need to check that it got set to some value after
    calling the function under test. This tweak should make the test pass
    consistently.

    Change-Id: I6c01d2958cf671c29622562689a15ca1ddea0a3c
    Closes-bug: #1270693

Changed in nova:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (stable/havana)

Fix proposed to branch: stable/havana
Review: https://review.openstack.org/68920

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: stable/havana
Review: https://review.openstack.org/69018

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (stable/havana)

Reviewed: https://review.openstack.org/68920
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=b69f2ca7b2bb6bf5788b16fd21800f53a6ec4807
Submitter: Jenkins
Branch: stable/havana

commit b69f2ca7b2bb6bf5788b16fd21800f53a6ec4807
Author: Russell Bryant <email address hidden>
Date: Thu Jan 23 16:03:37 2014 -0500

    Make test_poll_volume_usage_with_data more reliable

    This test includes 2 calls to time.time(). It assumes that the result
    from the second call may be greater than the first. This isn't
    definietly true and we see periodic failures of this test in the gate as
    a result.

    Change the test to not worry about the specific time value that gets
    set. We set _last_vol_usage_poll to 0 before calling the function under
    test. We really only need to check that it got set to some value after
    calling the function under test. This tweak should make the test pass
    consistently.

    Change-Id: I6c01d2958cf671c29622562689a15ca1ddea0a3c
    Closes-bug: #1270693
    (cherry picked from commit 7e18d67cc9c96a14e0ca24a41820441e41457738)

tags: added: in-stable-havana
Changed in nova:
milestone: none → icehouse-3
Thierry Carrez (ttx)
Changed in nova:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: icehouse-3 → 2014.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.