Continuation of 0dc32690fe158e4cb11c2c9bcc65acaf73b94a7a
Some code in ec2 api use Instance.id rather than InstanceIdMapping.id
directly while converting ec2 id to an instance object. This is very
dangerous if Instance.id is not equal to InstanceIdMapping.id for the
same instance uuid.
To avoid the id mapping confusion, this patch:
* uses instance_id_mappings.id instead of instances.id
* uses instance_uuid in ec2utils.id_to_ec2_inst_id
* removes ec2utils.ec2_instance_id_to_uuid
Reviewed: https:/ /review. openstack. org/23485 github. com/openstack/ nova/commit/ 67eb495e37f3622 d68bd07997b8680 049a2426d1
Committed: http://
Submitter: Jenkins
Branch: stable/folsom
commit 67eb495e37f3622 d68bd07997b8680 049a2426d1
Author: MotoKen <email address hidden>
Date: Mon Nov 5 19:45:11 2012 +0800
Decouple EC2 API from using instance id
Continuation of 0dc32690fe158e4 cb11c2c9bcc65ac af73b94a7a
Some code in ec2 api use Instance.id rather than InstanceIdMappi ng.id ng.id for the
directly while converting ec2 id to an instance object. This is very
dangerous if Instance.id is not equal to InstanceIdMappi
same instance uuid.
To avoid the id mapping confusion, this patch:
* uses instance_ id_mappings. id instead of instances.id id_to_ec2_ inst_id ec2_instance_ id_to_uuid
* uses instance_uuid in ec2utils.
* removes ec2utils.
Fixes bug 1145490
Change-Id: I22638f667c18ee fe542b03e31f1a3 aa2ce782db7 f70c6ca4b54053f 69c0dde81d)
(cherry picked from commit 79cc2a21b645138