Skip to content

Commit

Permalink
Avoid reading twice the same project
Browse files Browse the repository at this point in the history
This patch avoid an API call by adding
the security_groups field.

Change-Id: I9571788a5f875dddf7ea495d4837496399371da3
Partial-Bug: #1480901
  • Loading branch information
safchain authored and opencontrail-ci-admin committed Aug 6, 2015
1 parent a2057b4 commit d71fe4c
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -140,7 +140,7 @@ def _ensure_instance_exists(self, instance_id):

def _ensure_default_security_group_exists(self, proj_id):
proj_id = str(uuid.UUID(proj_id))
proj_obj = self._vnc_lib.project_read(id=proj_id)
proj_obj = self._vnc_lib.project_read(id=proj_id, fields=['security_groups'])
vnc_openstack.ensure_default_security_group(self._vnc_lib, proj_obj)
#end _ensure_default_security_group_exists

Expand Down

0 comments on commit d71fe4c

Please sign in to comment.