0d646d103590b367c28d1e9588edca610b361e1f,perfkitbenchmarker/providers/rackspace/rackspace_virtual_machine.py,RackspaceVirtualMachine,_PostCreate,#RackspaceVirtualMachine#,174
Before Change
@vm_util.Retry()
def _PostCreate(self):
Get the instance"s data.
env = os.environ.copy()
env.update(util.GetDefaultRackspaceNovaEnv(self.zone))
getinstance_cmd = [FLAGS.nova_path, "show", self.id]
stdout, _, _ = vm_util.IssueCommand(getinstance_cmd, env=env)
instance = util.ParseNovaTable(stdout)
if "status" in instance and instance["status"] == "ACTIVE":
self.ip_address = instance["accessIPv4"]
self.ip_address6 = instance["accessIPv6"]
After Change
get_cmd.flags["id"] = self.id
stdout, _, _ = get_cmd.Issue()
resp = json.loads(stdout)
self.internal_ip = resp["PrivateIPv4"]
self.ip_address = resp["PublicIPv4"]
def _Exists(self):
Returns true if the VM exists otherwise returns false.
if self.id is None:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 15
Instances
Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 0d646d103590b367c28d1e9588edca610b361e1f
Time: 2016-02-12
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/rackspace/rackspace_virtual_machine.py
Class Name: RackspaceVirtualMachine
Method Name: _PostCreate
Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 0d646d103590b367c28d1e9588edca610b361e1f
Time: 2016-02-12
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/rackspace/rackspace_disk.py
Class Name: RackspaceRemoteDisk
Method Name: _Create
Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 0d646d103590b367c28d1e9588edca610b361e1f
Time: 2016-02-12
Author: carlos.torres@rackspace.com
File Name: perfkitbenchmarker/providers/rackspace/rackspace_virtual_machine.py
Class Name: RackspaceVirtualMachine
Method Name: AddMetadata