3d95ae5cd11987e4c963baf4da374b1fa139b807,perfkitbenchmarker/providers/openstack/os_virtual_machine.py,OpenStackVirtualMachine,_Exists,#OpenStackVirtualMachine#,211

Before Change


  def _Exists(self):
    from novaclient.exceptions import NotFound
    try:
      return self.client.servers.get(self.id) is not None
    except NotFound:
      return False

  def _CheckCanaryCommand(self):

After Change


    if self.id is None:
      return False

    show_cmd = os_utils.OpenStackCLICommand(self, "server", "show", self.id)
    stdout, _, _ = show_cmd.Issue(suppress_warning=True)
    try:
      resp = json.loads(stdout)
    except ValueError:
      return False
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 3d95ae5cd11987e4c963baf4da374b1fa139b807
Time: 2016-06-29
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/openstack/os_virtual_machine.py
Class Name: OpenStackVirtualMachine
Method Name: _Exists


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 00f9f416594b404c02f87cec85d405cad341d4ad
Time: 2016-06-29
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/openstack/os_network.py
Class Name: OpenStackFirewall
Method Name: AllowICMP


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 0685052da871976e773c59dc732811019b90a612
Time: 2016-06-29
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/openstack/os_disk.py
Class Name: OpenStackDisk
Method Name: _Exists


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 00f9f416594b404c02f87cec85d405cad341d4ad
Time: 2016-06-29
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/openstack/os_network.py
Class Name: OpenStackFirewall
Method Name: AllowPort