EC2 Client Tokens don't work yet

Bug #1202404 reported by Burt Holzman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Burt Holzman
tempest
Fix Released
Medium
Burt Holzman

Bug Description

I'm not sure how this ever worked for me in a live devstack install -- maybe I had things configured strangely.

The issue is that both vm_state and task_state are 'building', while neither of those are allowed currently by
update_instance_metadata. If I allow that, it complicates matters since there's an rpcapi call for change_instance_metadata -- so the instance can access its own metadata, I guess.

I'm not sure of the right approach yet.

This needs tests in tempest too.

Tags: ec2 tags
Burt Holzman (holzman)
Changed in nova:
assignee: nobody → Burt Holzman (holzman)
Revision history for this message
Burt Holzman (holzman) wrote :

Sorry -- meant to say the vm_state is 'building'. Task_state is probably scheduling.

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/37627

Changed in nova:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

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

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

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

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

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

Sean Dague (sdague)
Changed in tempest:
assignee: nobody → Burt Holzman (holzman)
status: New → Confirmed
importance: Undecided → Medium
Changed in nova:
importance: Undecided → Medium
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tempest (master)

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

Changed in tempest:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/37687
Committed: http://github.com/openstack/nova/commit/0608c6f936ef7466114128fbc4b623c5058b66ed
Submitter: Jenkins
Branch: master

commit 0608c6f936ef7466114128fbc4b623c5058b66ed
Author: Burt Holzman <email address hidden>
Date: Wed Jul 17 17:03:27 2013 -0500

    Change EC2 client tokens to use system_metadata

    An EC2 client token is created as a result of RunInstances. The initial
    implementation called create_tags which uses per-instance metadata.
    However, we can't update per-instance metadata while an instance is still
    building because put the metadata updates in the messaging queue.

    We avoid this problem by using system_metadata instead of per-instance
    metadata. As an added bonus, users can't tamper with the token via the tags
    API.

    Fixes bug #1202404

    Change-Id: I8ff28d75154a30fe3b521926453b9e9cbdd9fead

Changed in nova:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tempest (master)

Reviewed: https://review.openstack.org/37838
Committed: http://github.com/openstack/tempest/commit/f70f2220f729cbf8e1df317d6d3a439bd861f06f
Submitter: Jenkins
Branch: master

commit f70f2220f729cbf8e1df317d6d3a439bd861f06f
Author: Burt Holzman <email address hidden>
Date: Thu Jul 18 23:36:31 2013 -0500

    Add boto tests for idempotent RunInstances calls

    The EC2 API supports providing a unique client token to
    the RunInstances call to ensure idempotency. In other words,
    multiple RunInstances call with the same client token will
    not start up multiple instances.

    This adds a test for this condition, including ensuring that
    a new instance is spawned when a client token is re-used
    after the original instance linked to it has been terminated.

    Fixes bug #1202404

    Change-Id: Ia11eb9ac082a623a1ad03b89fb6dbf7cad9f9c99

Changed in tempest:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → havana-3
status: Fix Committed → Fix Released
Sean Dague (sdague)
Changed in tempest:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: havana-3 → 2013.2
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.