The Instance object was assuming that security_groups and info_cache
were always joined for single instance_get() type queries. This is a poor
assumption to make. The object should explicitly ask for info_cache and
security_groups to be included in the DB object when necessary.
Also, we should actually fix sqlalchemy api to not join these always, but
that's probably too large of a change right now. Instead, make sure we
don't ask to join them twice in the same query.
Reviewed: https:/ /review. openstack. org/47662 github. com/openstack/ nova/commit/ 19953cee68092fa 93490320d0ebcac 3cf19f5fac
Committed: http://
Submitter: Jenkins
Branch: master
commit 19953cee68092fa 93490320d0ebcac 3cf19f5fac
Author: Chris Behrens <email address hidden>
Date: Thu Sep 19 17:51:16 2013 +0000
Fix Instance object assumptions about joins
The Instance object was assuming that security_groups and info_cache
were always joined for single instance_get() type queries. This is a poor
assumption to make. The object should explicitly ask for info_cache and
security_groups to be included in the DB object when necessary.
Also, we should actually fix sqlalchemy api to not join these always, but
that's probably too large of a change right now. Instead, make sure we
don't ask to join them twice in the same query.
Fixes bug 1227251
Change-Id: Ib39a3d041904fb 5ecebbe152f2fed e135a0cdb6f