Skip to content

Commit 8faa60f

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "Remove redundant group host setup" into stable/stein
2 parents 7a3a8f3 + 0313d81 commit 8faa60f

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

nova/scheduler/utils.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -898,13 +898,7 @@ def _get_group_details(context, instance_uuid, user_group_hosts=None):
898898
raise exception.UnsupportedPolicyException(reason=msg)
899899
# NOTE(melwitt): If the context is already targeted to a cell (during a
900900
# move operation), we don't need to scatter-gather.
901-
if context.db_connection:
902-
# We don't need to target the group object's context because it was
903-
# retrieved with the targeted context earlier in this method.
904-
group_hosts = set(group.get_hosts())
905-
else:
906-
group_hosts = set(_get_instance_group_hosts_all_cells(context,
907-
group))
901+
group_hosts = set(group.get_hosts())
908902
user_hosts = set(user_group_hosts) if user_group_hosts else set()
909903
return GroupDetails(hosts=user_hosts | group_hosts,
910904
policy=group.policy, members=group.members)

0 commit comments

Comments
 (0)