4da37abc3937edf62249daa010f5e522c6c04fd4,perfkitbenchmarker/providers/aws/aws_managed_relational_db.py,AwsManagedRelationalDb,_IsInstanceReady,#AwsManagedRelationalDb#Any#Any#,480
Before Change
True if the resource was ready in time, False if the wait timed out
or an Exception occurred.
cmd = util.AWS_PREFIX + [
"rds",
"describe-db-instances",
"--db-instance-identifier=%s" % instance_id,
"--region=%s" % self.region
]
start_time = datetime.datetime.now()
while True:
if (datetime.datetime.now() - start_time).seconds >= timeout:
logging.exception("Timeout waiting for sql instance to be ready")
return False
stdout, _, _ = vm_util.IssueCommand(cmd, suppress_warning=True)
try:
json_output = json.loads(stdout)
state = json_output["DBInstances"][0]["DBInstanceStatus"]
After Change
state = json_output["DBInstances"][0]["DBInstanceStatus"]
pending_values = json_output["DBInstances"][0]["PendingModifiedValues"]
logging.info("Instance state: %s", state)
if pending_values:
logging.info("Pending values: %s", (str(pending_values)))
if state == "available" and not pending_values:
break
except:
logging.exception("Error attempting to read stdout. Creation failure.")
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 5
Instances Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 4da37abc3937edf62249daa010f5e522c6c04fd4
Time: 2018-03-07
Author: tohaowu@google.com
File Name: perfkitbenchmarker/providers/aws/aws_managed_relational_db.py
Class Name: AwsManagedRelationalDb
Method Name: _IsInstanceReady
Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 38184fca0234ef4da34b84497b2cd0f4009a9c5b
Time: 2018-03-08
Author: nathante@google.com
File Name: perfkitbenchmarker/providers/aws/aws_managed_relational_db.py
Class Name: AwsManagedRelationalDb
Method Name: _IsInstanceReady
Project Name: tensorflow/tensorflow
Commit Name: 448e080c752a1b5f54c422401b41e824b0274a91
Time: 2020-11-17
Author: crccw@google.com
File Name: tensorflow/python/distribute/multi_process_lib.py
Class Name:
Method Name: _set_spawn_exe_path
Project Name: tensorflow/tensorflow
Commit Name: de336139770c6e9e035c0e402375efda48d75301
Time: 2020-11-18
Author: crccw@google.com
File Name: tensorflow/python/distribute/multi_process_lib.py
Class Name:
Method Name: _set_spawn_exe_path