delete() 공개 메소드

The DeleteDBInstance API deletes a previously provisioned RDS instance. A successful response from the web service indicates the request was received correctly. If a final DBSnapshot is requested the status of the RDS instance will be "deleting" until the DBSnapshot is created. DescribeDBInstance is used to monitor the status of this operation. This cannot be canceled or reverted once submitted
public delete ( boolean $skipFinalSnapshot = null, string $finalDBSnapshotIdentifier = null ) : DBInstanceData
$skipFinalSnapshot boolean optional Determines whether a final DB Snapshot is created before the DB Instance is deleted
$finalDBSnapshotIdentifier string optional The DBSnapshotIdentifier of the new DBSnapshot created when SkipFinalSnapshot is set to false
리턴 DBInstanceData Returns created DBInstance
예제 #1
0
파일: RdsTest.php 프로젝트: mheydt/scalr
 /**
  * Remove test instance
  * @param DBInstanceData $dbi
  * @throws ClientException
  */
 protected function removeDBInstance(DBInstanceData $dbi)
 {
     $dbi->delete(true);
     $this->assertInstanceOf($this->getRdsClassName('DataType\\DBInstanceData'), $dbi);
     for ($to = 1, $t = time(); time() - $t < 600 && $dbi->dBInstanceStatus == DBInstanceData::STATUS_DELETING; $to += 10) {
         sleep($to);
         try {
             $dbi = $dbi->refresh();
         } catch (ClientException $e) {
             if ($e->getErrorData()->getCode() == ErrorData::ERR_DB_INSTANCE_NOT_FOUND) {
                 break;
             }
             throw $e;
         }
     }
 }